diff --git a/rc_util.py b/rc_util.py index 2b39ae522a1c2a28111e3a0e047938a48da028bd..946c560e2a5075bde3b0101d3d504b7b62b1bd33 100644 --- a/rc_util.py +++ b/rc_util.py @@ -1,3 +1,4 @@ +import argparse from rc_rmq import RCRMQ import json @@ -44,3 +45,10 @@ def consume(username, callback=worker, debug=False): rc_rmq.disconnect() return { 'success' : True } + +def get_args(): + # Parse arguments + parser = argparse.ArgumentParser() + parser.add_argument('-v', '--verbose', action='store_true', help='verbose output') + parser.add_argument('-n', '--dry-run', action='store_true', help='enable dry run mode') + return parser.parse_args()