0003-makepkg-check_pkgver-Report-what-the-bad-pkgver-is.patch 1.2 KB

1234567891011121314151617181920212223242526272829303132
  1. From fb1606f4bba3386fd8d1cc710423c6e629060b86 Mon Sep 17 00:00:00 2001
  2. From: Luke Shumaker <lukeshu@parabola.nu>
  3. Date: Mon, 6 Aug 2018 23:51:47 -0400
  4. Subject: [PATCH 3/4] makepkg: check_pkgver: Report what the bad pkgver is
  5. For consistency with check_epoch and check_pkgrel.
  6. I think that this is important because if there are multiple
  7. provides/depends/whatever that include a version, and one of them is
  8. malformed, including the bad version in the error message identified
  9. which one is the problem.
  10. ---
  11. scripts/libmakepkg/lint_pkgbuild/pkgver.sh.in | 2 +-
  12. 1 file changed, 1 insertion(+), 1 deletion(-)
  13. diff --git a/scripts/libmakepkg/lint_pkgbuild/pkgver.sh.in b/scripts/libmakepkg/lint_pkgbuild/pkgver.sh.in
  14. index c105212b..65216b64 100644
  15. --- a/scripts/libmakepkg/lint_pkgbuild/pkgver.sh.in
  16. +++ b/scripts/libmakepkg/lint_pkgbuild/pkgver.sh.in
  17. @@ -38,7 +38,7 @@ check_pkgver() {
  18. fi
  19. if [[ $ver = *[[:space:]/:-]* ]]; then
  20. - error "$(gettext "%s is not allowed to contain colons, forward slashes, hyphens or whitespace.")" "pkgver${type:+ in $type}"
  21. + error "$(gettext "%s is not allowed to contain colons, forward slashes, hyphens or whitespace; got %s.")" "pkgver${type:+ in $type}" "$ver"
  22. return 1
  23. fi
  24. }
  25. --
  26. 2.18.0