Skip to content

Commit

Permalink
Made it possible to create project without templates.
Browse files Browse the repository at this point in the history
  • Loading branch information
naitikrambhia committed Oct 18, 2024
1 parent ccf09ae commit 3300a3a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
3 changes: 2 additions & 1 deletion pros/conductor/conductor.py
Original file line number Diff line number Diff line change
Expand Up @@ -377,7 +377,8 @@ def new_project(self, path: str, no_default_libs: bool = False, **kwargs) -> Pro
if 'version' in kwargs:
if kwargs['version'] == 'latest':
kwargs['version'] = '>=0'
self.apply_template(proj, identifier='kernel', **kwargs)
if not no_default_libs:
self.apply_template(proj, identifier='kernel', **kwargs)
proj.save()

if not no_default_libs:
Expand Down
4 changes: 3 additions & 1 deletion pros/conductor/project/ProjectReport.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,10 @@ def __str__(self):
f' ({self.project["name"]})' if self.project["name"] else ''
s += '\n'
rows = [t.values() for t in self.project["templates"]]
headers = [h.capitalize() for h in self.project["templates"][0].keys()]

headers = [h.capitalize() for h in self.project["templates"][0].keys()]if self.project["templates"] else []
s += tabulate.tabulate(rows, headers=headers)

return s

def __getstate__(self):
Expand Down

0 comments on commit 3300a3a

Please sign in to comment.