spack style: add --root option (#25085)
				
					
				
			This adds a `--root` option so that `spack style` can check style for a spack instance other than its own. We also change the inner workings of `spack style` so that `--config FILE` (and similar options for the various tools) options are used. This ensures that when `spack style` runs, it always uses the config from the running spack, and does *not* pick up configuration from the external root. - [x] add `--root` option to `spack style` - [x] add `--config` (or similar) option when invoking style tools - [x] add a test that verifies we can check an external instance
This commit is contained in:
		| @@ -1008,7 +1008,7 @@ _spack_find() { | ||||
| _spack_flake8() { | ||||
|     if $list_options | ||||
|     then | ||||
|         SPACK_COMPREPLY="-h --help -b --base -a --all -r --root-relative -U --no-untracked -f --fix --no-isort --no-flake8 --no-mypy --black" | ||||
|         SPACK_COMPREPLY="-h --help -b --base -a --all -r --root-relative -U --no-untracked -f --fix --no-isort --no-flake8 --no-mypy --black --root" | ||||
|     else | ||||
|         SPACK_COMPREPLY="" | ||||
|     fi | ||||
| @@ -1614,7 +1614,7 @@ _spack_stage() { | ||||
| _spack_style() { | ||||
|     if $list_options | ||||
|     then | ||||
|         SPACK_COMPREPLY="-h --help -b --base -a --all -r --root-relative -U --no-untracked -f --fix --no-isort --no-flake8 --no-mypy --black" | ||||
|         SPACK_COMPREPLY="-h --help -b --base -a --all -r --root-relative -U --no-untracked -f --fix --no-isort --no-flake8 --no-mypy --black --root" | ||||
|     else | ||||
|         SPACK_COMPREPLY="" | ||||
|     fi | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Todd Gamblin
					Todd Gamblin