Skip to content

Commit

Permalink
Make src the only requirement for building.
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelsproul committed Aug 4, 2013
1 parent 0cc022f commit 7cf9e6d
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions ino/runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,14 +59,21 @@ def main():

# Create a .build directory if required
valid_project = os.path.isdir(e.src_dir)
do_anywhere = "init clean list-models serial"
run_anywhere = "init clean list-models serial"

if current_command not in do_anywhere:
if current_command not in run_anywhere:
if not valid_project:
raise Abort("No project found in this directory.")
elif not os.path.isdir(e.build_dir):

# For valid projects create .build & lib
if not os.path.isdir(e.build_dir):
os.makedirs(e.build_dir)

if not os.path.isdir(e.lib_dir):
os.makedirs(e.lib_dir)
with open('lib/.holder', 'w') as f:
f.write("")

args.func(args)
except Abort as exc:
print colorize(str(exc), 'red')
Expand Down

0 comments on commit 7cf9e6d

Please sign in to comment.