mirror of
				https://github.com/nvm-sh/nvm.git
				synced 2025-10-31 18:25:52 +08:00 
			
		
		
		
	Return 1 so exit status is not null on error
This commit is contained in:
		
							
								
								
									
										3
									
								
								nvm.sh
									
									
									
									
									
								
							
							
						
						
									
										3
									
								
								nvm.sh
									
									
									
									
									
								
							| @@ -321,13 +321,14 @@ nvm() | |||||||
|         fi |         fi | ||||||
|       else |       else | ||||||
|         echo "nvm: install $VERSION failed!" |         echo "nvm: install $VERSION failed!" | ||||||
|  |         return 1 | ||||||
|       fi |       fi | ||||||
|     ;; |     ;; | ||||||
|     "uninstall" ) |     "uninstall" ) | ||||||
|       [ $# -ne 2 ] && nvm help && return |       [ $# -ne 2 ] && nvm help && return | ||||||
|       if [[ $2 == `nvm_version` ]]; then |       if [[ $2 == `nvm_version` ]]; then | ||||||
|         echo "nvm: Cannot uninstall currently-active node version, $2." |         echo "nvm: Cannot uninstall currently-active node version, $2." | ||||||
|         return |         return 1 | ||||||
|       fi |       fi | ||||||
|       VERSION=`nvm_version $2` |       VERSION=`nvm_version $2` | ||||||
|       if [ ! -d $NVM_DIR/$VERSION ]; then |       if [ ! -d $NVM_DIR/$VERSION ]; then | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user