mirror of
				https://github.com/nvm-sh/nvm.git
				synced 2025-10-31 10:15:53 +08:00 
			
		
		
		
	Properly pass a space-separated list of packages to npm install
				
					
				
			Fixes #490.
This commit is contained in:
		
							
								
								
									
										2
									
								
								nvm.sh
									
									
									
									
									
								
							
							
						
						
									
										2
									
								
								nvm.sh
									
									
									
									
									
								
							| @@ -793,7 +793,7 @@ nvm() { | ||||
|       local INSTALLS | ||||
|       INSTALLS=$(nvm use $VERSION > /dev/null && npm list --global --parseable --depth=0 2> /dev/null | tail -n +2 | \grep -o -e '/[^/]*$' | cut -c 2- | \grep -v npm | xargs) | ||||
|  | ||||
|       npm install -g --quiet $INSTALLS | ||||
|       echo "$INSTALLS" | xargs npm install -g --quiet | ||||
|     ;; | ||||
|     "clear-cache" ) | ||||
|       rm -f $NVM_DIR/v* "$(nvm_version_dir)" 2>/dev/null | ||||
|   | ||||
		Reference in New Issue
	
	Block a user