index : pacman | |
Archlinux32 fork of pacman | gitolite user |
summaryrefslogtreecommitdiff |
-rw-r--r-- | scripts/libmakepkg/lint_pkgbuild/epoch.sh.in | 10 |
diff --git a/scripts/libmakepkg/lint_pkgbuild/epoch.sh.in b/scripts/libmakepkg/lint_pkgbuild/epoch.sh.in index 93bd05c1..c98f91b0 100644 --- a/scripts/libmakepkg/lint_pkgbuild/epoch.sh.in +++ b/scripts/libmakepkg/lint_pkgbuild/epoch.sh.in @@ -29,9 +29,15 @@ source "$LIBRARY/util/message.sh" lint_pkgbuild_functions+=('lint_epoch') -lint_epoch() { +check_epoch() { + local epoch=$1 type=$2 + if [[ $epoch != *([[:digit:]]) ]]; then - error "$(gettext "%s must be an integer, not %s.")" "epoch" "$epoch" + error "$(gettext "%s must be an integer, not %s.")" "epoch${type:+ in $type}" "$epoch" return 1 fi } + +lint_epoch() { + check_epoch "$epoch" +} |