You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
parser = argparse.ArgumentParser(prog='MakeMaker',description='Create a MakeFile for a C++ program, with compile, test and clean options',formatter_class=argparse.ArgumentDefaultsHelpFormatter)
parser.add_argument('source_file',nargs=1,help='Source file to be compiled')
parser.add_argument('-o','--output',nargs=1,default=['exec'],type=str,help='Defines the output name.')
args = vars(parser.parse_args())
source = args['source_file'][0]
output = args['output'][0]
if(not source.endswith('.cpp')):
source += '.cpp'
print('Generating Makefile for "'+source+'" with output name: "'+output+'"')