Browse Source

[Fix] don’t use bash `==` in conditionals

Jordan Harband 9 years ago
parent
commit
a94ade8ec2
No known key found for this signature in database
GPG Key ID: 64A196AEE0916D55
  1. 2
      nvm.sh

2
nvm.sh

@ -879,7 +879,7 @@ nvm_ls_remote_index_tab() {
nvm_checksum() { nvm_checksum() {
local NVM_CHECKSUM local NVM_CHECKSUM
if [ -z "$3" ] || [ "$3" == "sha1" ]; then if [ -z "$3" ] || [ "$3" = "sha1" ]; then
if nvm_has "sha1sum" && ! nvm_is_alias "sha1sum"; then if nvm_has "sha1sum" && ! nvm_is_alias "sha1sum"; then
NVM_CHECKSUM="$(command sha1sum "$1" | command awk '{print $1}')" NVM_CHECKSUM="$(command sha1sum "$1" | command awk '{print $1}')"
elif nvm_has "sha1" && ! nvm_is_alias "sha1"; then elif nvm_has "sha1" && ! nvm_is_alias "sha1"; then

Loading…
Cancel
Save