Skip to content

Commit

Permalink
add -v option.
Browse files Browse the repository at this point in the history
  • Loading branch information
Jerry Shi committed Dec 24, 2021
1 parent 011c999 commit 270bb18
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions cleanup-roster.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,13 +51,15 @@ def write_csv(file, student_list, fields, nl = None):
csvwriter.writerow(s.get_fields(fields))

parser = argparse.ArgumentParser(description='Clean up downloaded roster from HuskyCT')
parser.add_argument('infile', nargs='?', help='Input file.')
parser.add_argument('infile', help='Input file.')
parser.add_argument('-o', nargs='?', default='', const='', help='Output file.')
parser.add_argument('-f', nargs='+', default='', help='List of field numbers.')
parser.add_argument("-a", action='store_true', default=False, help='Append to the output file.')
parser.add_argument("-v", action='store_true', default=False, help='Verbose.')

args = parser.parse_args()
print(args)
if args.v:
print(args)

student_list = []
student = None
Expand Down

0 comments on commit 270bb18

Please sign in to comment.