summaryrefslogtreecommitdiffstats
path: root/commands/check
diff options
context:
space:
mode:
Diffstat (limited to 'commands/check')
-rwxr-xr-xcommands/check16
1 files changed, 16 insertions, 0 deletions
diff --git a/commands/check b/commands/check
new file mode 100755
index 0000000..4b416d1
--- /dev/null
+++ b/commands/check
@@ -0,0 +1,16 @@
+#!/bin/sh -e
+empty=
+if [ $# -ge 1 ]; then
+ packages="$*"
+else
+ packages="$(dh_listpackages -s)"
+fi
+for pkg in $packages; do
+ if [ -z "$(find debian/$pkg -type f)" ]; then
+ echo "$pkg will be empty" >&2
+ empty=1
+ fi
+done
+if [ "$empty" -a -z "$KW_CHECK_NONFATAL" ]; then
+ exit 1
+fi