summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorGeorge Todd Gamblin <gamblin2@llnl.gov>2014-08-18 23:11:02 -0700
committerGeorge Todd Gamblin <gamblin2@llnl.gov>2014-08-18 23:11:02 -0700
commit42e27d04c17b8f011a1882bb45f899187c8ffa59 (patch)
tree39c23e96c4782a252962a004e9946dec3e493327 /bin
parent884a4fecd18eb983ae02ead366d638a735e5170b (diff)
parentb601fd08caf21b5fc11e6998a5ebd20a04ac57ad (diff)
downloadspack-42e27d04c17b8f011a1882bb45f899187c8ffa59.tar.gz
spack-42e27d04c17b8f011a1882bb45f899187c8ffa59.tar.bz2
spack-42e27d04c17b8f011a1882bb45f899187c8ffa59.tar.xz
spack-42e27d04c17b8f011a1882bb45f899187c8ffa59.zip
Merge pull request #19 in SCALE/spack from features/modules to develop
# By Todd Gamblin (4) and David Beckingsale (2) # Via Todd Gamblin * commit 'b601fd08caf21b5fc11e6998a5ebd20a04ac57ad': Bugfixes for csh environment modules. Bugfixes, more consolidation of modules code. Add csh/tcsh support for modules Consolidate most module code into spack.modules and spack.cmd.module Fixed up module support Added inital module support
Diffstat (limited to 'bin')
-rwxr-xr-xbin/spack7
1 files changed, 7 insertions, 0 deletions
diff --git a/bin/spack b/bin/spack
index c63178b191..f2b5d1d583 100755
--- a/bin/spack
+++ b/bin/spack
@@ -75,6 +75,13 @@ for cmd in spack.cmd.commands:
module = spack.cmd.get_module(cmd)
subparser = subparsers.add_parser(cmd, help=module.description)
module.setup_parser(subparser)
+
+# Just print help and exit if run with no arguments at all
+if len(sys.argv) == 1:
+ parser.print_help()
+ sys.exit(1)
+
+# actually parse the args.
args = parser.parse_args()
# Set up environment based on args.