X-Git-Url: http://git.ozo.com/?a=blobdiff_plain;f=include%2Fshell.sh;h=f6be6c526f26fb489cc660d7201bce3c3a1117b7;hb=23660965c9671a573d958374ce1ef0b7c5b317b8;hp=1e60692b97fffcc1864146345da6b761cbe6c3f7;hpb=97c8cb1b64a660538b7ef6cf5a9b98f904a8bccc;p=openwrt-10.03%2F.git diff --git a/include/shell.sh b/include/shell.sh index 1e60692b9..f6be6c526 100644 --- a/include/shell.sh +++ b/include/shell.sh @@ -28,3 +28,7 @@ trapret() {( } } )} + +md5s() { + which md5sum 2>&1 >/dev/null && md5sum "$@" | awk '{print $1}' || md5 "$@" +}