Skip to content
Snippets Groups Projects
Select Git revision
  • 0e31d75a6dde0c66a29d1a86f4dfe83b0f9b47e7
  • master default
  • nrb/rebase-20200624
  • nrb/rebase-recommended
  • nrb/old-deprectated-devices
  • next
6 results

config_template.js

Blame
  • sha512sum.sh 381 B
    #!/bin/sh
    
    check_command() {
    	which $1 >/dev/null 2>&1
    }
    
    if check_command sha512sum; then
    	ret="$(sha512sum "$@")"
    elif check_command shasum; then
    	ret="$(shasum -a 512 "$@")"
    elif check_command cksum; then
    	ret="$(cksum -q -a sha512 "$@")"
    else
    	echo "$0: no suitable sha512sum implementation was found" >&1
    	exit 1
    fi
    
    [ "$?" -eq 0 ] || exit 1
    
    echo "$ret" | awk '{ print $1 }'