File: check-md5sum-etc

package info (click to toggle)
base-files 14
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 480 kB
  • sloc: sh: 194; makefile: 67
file content (8 lines) | stat: -rw-r--r-- 223 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
#!/bin/sh
file=$1
md5=$(md5sum share/${file} | cut -f 1 -d " ")
if ! grep -q "$md5" share/${file}.md5sums; then
  echo Error: share/${file}.md5sums is incomplete.
  echo Need to add "$md5" with current version.
  exit 1
fi