Shell detection: filter preceding "-"
On OSX, the shell detection code may get a preceding dash, like "-bash". This adds a filter to remove it.
This commit is contained in:
		 Christoph Junghans
					Christoph Junghans
				
			
				
					committed by
					
						 scheibelp
						scheibelp
					
				
			
			
				
	
			
			
			 scheibelp
						scheibelp
					
				
			
						parent
						
							90d50a0cee
						
					
				
				
					commit
					80ac613391
				
			| @@ -202,7 +202,7 @@ export SPACK_ROOT=${_sp_prefix} | |||||||
| # Determine which shell is being used | # Determine which shell is being used | ||||||
| # | # | ||||||
| function _spack_determine_shell() { | function _spack_determine_shell() { | ||||||
| 	ps -p $$ | tail -n 1 | awk '{print $4}' | xargs basename | 	ps -p $$ | tail -n 1 | awk '{print $4}' | sed 's/^-//' | xargs basename | ||||||
| } | } | ||||||
| export SPACK_SHELL=$(_spack_determine_shell) | export SPACK_SHELL=$(_spack_determine_shell) | ||||||
|  |  | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user