Compare commits

..

2 Commits

Author SHA1 Message Date
Vekhir --
00df744eb2 Merge branch 'fix-pkgrel-pkgver-match' into 'master'
fix(pkgbuild.sh): Use grep -Fx to check for pkgrel and pkgver declaration

Closes #242

See merge request archlinux/devtools!283
2025-08-20 12:58:34 +00:00
Vekhir
6dd555ed1f fix(pkgbuild.sh): Use grep -Fx to check for pkgrel and pkgver declaration
In order to automatically replace pkgrel and pkgver, we must first check
that they are declared in the usual way as a key-value pair.
If pkgrel or pkgver contain special characters like +, they are currently
interpreted as regex. Use --fixed-strings to instead signify that they should
be literal patterns. Since the declaration must be on its own line and anchors
can't be in literal patterns, also specify --line-regexp to only consider
whole line matches.

Using sed with --extended-regexp fails for a similar reason in that the +
is treated as a special character. As it's only use was to save some
typing (not repeating pkgver= and pkgrel=), remove the option.
2025-08-20 14:55:32 +02:00

Diff Content Not Available