Skip to content
This repository has been archived by the owner on Jan 28, 2020. It is now read-only.

Commit

Permalink
Cleaned up the weaver script.
Browse files Browse the repository at this point in the history
  • Loading branch information
jcsackett committed Jul 15, 2009
1 parent 95ca4c7 commit 6418697
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion weaver.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,19 @@ def init(args):
os.path.join(target_dir, 'settings.py')
)

def build(args):
pass

commands = {
'init':init,
'build':build
}

if __name__ == '__main__':
cmd = sys.argv[1]
args = sys.argv[2:]

commands[cmd](args)
try:
commands[cmd](args)
except KeyError:
print '%s is not a weaver command.' % cmd

0 comments on commit 6418697

Please sign in to comment.