Commit e3e0e4ba authored by Samuel Tan's avatar Samuel Tan
Browse files

changed -i to -x for xyz_file command line option

parent 317045a1
......@@ -48,7 +48,7 @@ def prettyPrint(contentsList, out_filename = None):
def usage():
usage_str = """
Usage:\n \t qcpp <task_file> -i <xyz_file> -o <output_file> -t <task> -s <template>
Usage:\n \t qcpp <task_file> -x <xyz_file> -o <out_filename> -t <task> -s <template>
See the "templates" directory for examples of templates
"""
warning(usage_str)
......@@ -62,7 +62,7 @@ def main():
# optional parameters that take an arg must be followed by a ":"
try:
opts, args = getopt.getopt(sys.argv[1:], "hi:o:t:s:")
opts, args = getopt.getopt(sys.argv[1:], "hx:o:t:s:")
except getopt.GetoptError:
usage()
sys.exit(3)
......@@ -73,7 +73,7 @@ def main():
sys.exit()
# check command line for task, xyz, and template
essentials = ["-t", "-i"]
essentials = ["-t", "-x"]
if all(a in optDict for a in essentials):
pass
......@@ -97,7 +97,7 @@ def main():
#sys.exit(2)
# override task file defaults with optional arguments
if "-i" in optDict:
if "-x" in optDict:
taskDict["using"] = optDict["-i"]
elif "-o" in optDict:
taskDict["out_filename"] = optDict["-o"]
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment