Skip to content

Commit

Permalink
Merge pull request rvm#1321 from alanzoppa/zsh_fix_for_debian_lenny
Browse files Browse the repository at this point in the history
Verbose function declaration because ZSH on Debian Lenny complains
  • Loading branch information
mpapis committed Nov 20, 2012
2 parents d96352d + d7040f6 commit 115f2cd
Showing 1 changed file with 14 additions and 3 deletions.
17 changes: 14 additions & 3 deletions scripts/functions/checksum
Expand Up @@ -74,9 +74,20 @@ __rvm_checksum_calculate_file()
_checksum_sha512="$( __rvm_sha__calculate 512 "${1:-}" )"
}

__rvm_checksum_none() [[ -z "${_checksum_md5:-}" && -z "${_checksum_sha512:-}" ]]
__rvm_checksum_any() [[ -n "${_checksum_md5:-}" || -n "${_checksum_sha512:-}" ]]
__rvm_checksum_all() [[ -n "${_checksum_md5:-}" && -n "${_checksum_sha512:-}" ]]
__rvm_checksum_none()
{
[[ -z "${_checksum_md5:-}" && -z "${_checksum_sha512:-}" ]]
}

__rvm_checksum_any()
{
[[ -n "${_checksum_md5:-}" || -n "${_checksum_sha512:-}" ]]
}

__rvm_checksum_all()
{
[[ -n "${_checksum_md5:-}" && -n "${_checksum_sha512:-}" ]]
}

# __rvm_checksum_validate_file {file}
# ENV in: _checksum_md5 _checksum_sha512
Expand Down

0 comments on commit 115f2cd

Please sign in to comment.