diff --git a/VERSION b/VERSION index 57970275..4ab61e83 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -Version 2.00.0 (2012-07-16 14:11:51) dev +Version 2.00.0 (2012-07-16 14:25:16) dev diff --git a/gluon/shell.py b/gluon/shell.py index e5e2bc20..b9c10d57 100644 --- a/gluon/shell.py +++ b/gluon/shell.py @@ -172,8 +172,13 @@ def run( die(errmsg) adir = os.path.join('applications', a) if not os.path.exists(adir): - if raw_input('application %s does not exist, create (y/n)?' - % a).lower() in ['y', 'yes']: + if sys.stdin and not sys.stdin.name == '/dev/null': + c = raw_input('application %s does not exist, create (y/n)?' % a) + else: + logging.warn('application does not exist and will not be created') + return + if c.lower() in ['y', 'yes']: + os.mkdir(adir) w2p_unpack('welcome.w2p', adir) for subfolder in ['models','views','controllers', 'databases',