spack/share/spack
Todd Gamblin a7b43f1015 spack python: add -m option to run modules as scripts
It's often useful to run a module with `python -m`, e.g.:

    python -m pyinstrument script.py

Running a python script this way was hard, though, as `spack python` did
not have a similar `-m` option.  This PR adds a `-m` option to `spack
python` so that we can do things like this:

    spack python -m pyinstrument ./test.py

This makes it easy to write a script that uses a small part of Spack and
then profile it.  Previously thee easiest way to do this was to write a
custom Spack command, which is often overkill.
2020-02-12 16:45:41 -08:00
..
bash Add spack config list command for tab completion (#14474) 2020-01-24 17:28:20 -08:00
csh shell support: spack load no longer needs modules (#14062) 2020-01-22 22:36:02 -08:00
docker copyright: update copyright dates for 2020 (#14328) 2019-12-30 22:36:56 -08:00
docs/docker/module-file-tutorial copyright: update copyright dates for 2020 (#14328) 2019-12-30 22:36:56 -08:00
logo add artisanal handcrafted SVG Spack logo. (#6165) 2017-11-06 22:42:16 -08:00
qa commands: add simple spack commands --update-completion argument (#14607) 2020-01-23 14:48:06 -08:00
templates spack containerize generates containers from envs (#14202) 2020-01-30 17:19:55 -08:00
setup-env.csh copyright: update copyright dates for 2020 (#14328) 2019-12-30 22:36:56 -08:00
setup-env.sh shell support: spack load no longer needs modules (#14062) 2020-01-22 22:36:02 -08:00
spack-completion.bash spack python: add -m option to run modules as scripts 2020-02-12 16:45:41 -08:00