Mercurial > hg > MakeItSo
comparison makeitso/python.py @ 114:b8d5d2041fe0
stub out project name -> package name
author | Jeff Hammel <jhammel@mozilla.com> |
---|---|
date | Mon, 17 Jan 2011 14:38:42 -0800 |
parents | bad70fb08b15 |
children | 7dbc3cdadffe |
comparison
equal
deleted
inserted
replaced
113:c3b8ce33d3ad | 114:b8d5d2041fe0 |
---|---|
54 """ | 54 """ |
55 | 55 |
56 # get project from output directory | 56 # get project from output directory |
57 variables['project'] = os.path.basename(output) | 57 variables['project'] = os.path.basename(output) |
58 | 58 |
59 # get package name from project | |
60 # XXX could have looser restrictions with transforms | |
61 assert variables['project'].isalpha(), 'Project name must be just letters' | |
62 variables['package'] = variables['project'].lower() | |
63 | |
59 # dependencies | 64 # dependencies |
60 dependencies = set([]) | 65 dependencies = set([]) |
61 for template, dependency in self.dependencies.items(): | 66 for template, dependency in self.dependencies.items(): |
62 dependencies.update(dependency) | 67 dependencies.update(dependency) |
63 dependencies = list(dependencies) | 68 dependencies = list(dependencies) |