Hello, I've started experimenting with `pkgctl` for package maintainance. I am currently using it for a local copy of the AUR package "ampcode". I set up the nvchecker file to be: --- [ampcode] source = "npm" npm = "@sourcegraph/amp" from_pattern = '([0-9.]+)-([a-z0-9]+)' to_pattern = '\1+\2' --- And my pkgver is: pkgver="0.0.1762617680+gaa03ea" However, `pkgctl version upgrade` reports: ==> ERROR: Non-standard pkgver declaration What am I doing wrong? Bests, -- Giovanni Santini
On Mon, 10 Nov 2025 at 13:58, Giovanni Santini <giovannisantini93@yahoo.it> wrote:
Hello,
I've started experimenting with `pkgctl` for package maintainance.
I am currently using it for a local copy of the AUR package "ampcode".
I set up the nvchecker file to be:
---
[ampcode] source = "npm" npm = "@sourcegraph/amp" from_pattern = '([0-9.]+)-([a-z0-9]+)' to_pattern = '\1+\2' ---
And my pkgver is:
pkgver="0.0.1762617680+gaa03ea"
However, `pkgctl version upgrade` reports:
==> ERROR: Non-standard pkgver declaration
What am I doing wrong?
Bests,
-- Giovanni Santini
That `+` sign is not allowed in `pkgver`. See <https://wiki.archlinux.org/title/PKGBUILD#pkgver>:
It can contain letters, numbers, periods and underscores, but not a hyphen (-). If the author of the software uses one, replace it with an underscore (_).
Hello, On 2025-11-10 21:58, Tiago de Paula wrote:
That `+` sign is not allowed in `pkgver`. See <https://wiki.archlinux.org/title/PKGBUILD#pkgver>:
It can contain letters, numbers, periods and underscores, but not a hyphen (-). If the author of the software uses one, replace it with an underscore (_).
I tried to replace the pluses with underscore, but still getting the same error: ``` (20:37) giovanni @ ~/Projects/AUR/wip/ampcode $ grep ^pkgver PKGBUILD pkgver="0.0.1762617680_gaa03ea" (20:37) giovanni @ ~/Projects/AUR/wip/ampcode $ cat .nvchecker.toml [ampcode] source = "npm" npm = "@sourcegraph/amp" from_pattern = '([0-9.]+)-([a-z0-9]+)' to_pattern = '\1_\2' (20:37) giovanni @ ~/Projects/AUR/wip/ampcode $ pkgctl version upgrade 📡 ampcode: query latest version ⌛ Upgrading: 1/1 [100%] ⠄⠀==> ERROR: Non-standard pkgver declaration ``` Is it a `pkgctl` bug? -- Giovanni Santini
On Tue, 11 Nov 2025 at 16:38, Giovanni Santini <giovannisantini93@yahoo.it> wrote:
Hello,
On 2025-11-10 21:58, Tiago de Paula wrote:
That `+` sign is not allowed in `pkgver`. See <https://wiki.archlinux.org/title/PKGBUILD#pkgver>:
It can contain letters, numbers, periods and underscores, but not a hyphen (-). If the author of the software uses one, replace it with an underscore (_).
I tried to replace the pluses with underscore, but still getting the same error:
```
(20:37) giovanni @ ~/Projects/AUR/wip/ampcode $ grep ^pkgver PKGBUILD pkgver="0.0.1762617680_gaa03ea" (20:37) giovanni @ ~/Projects/AUR/wip/ampcode $ cat .nvchecker.toml [ampcode] source = "npm" npm = "@sourcegraph/amp" from_pattern = '([0-9.]+)-([a-z0-9]+)' to_pattern = '\1_\2' (20:37) giovanni @ ~/Projects/AUR/wip/ampcode $ pkgctl version upgrade 📡 ampcode: query latest version ⌛ Upgrading: 1/1 [100%] ⠄⠀==> ERROR: Non-standard pkgver declaration
```
Is it a `pkgctl` bug?
-- Giovanni Santini
I can't reproduce this issue locally. Testing your `.nvchecker.toml` on the current `ampcode` from AUR, I get this instead: ```console
pkgctl version upgrade Failure x ampcode: failed to update checksums for version 0.0.1762891276_ge61ff2
Upgraded ! ampcode: upgraded from version 0.0.1756886778 to 0.0.1762891276_ge61ff2 ``` And then changing the PKGBUILD to use the NPM tarball (`source=("https://registry.npmjs.org/@sourcegraph/amp/-/amp-${pkgver/_/-}.tgz")`) does work for me: ```console
pkgctl version upgrade Upgraded ! ampcode: upgraded from version 0.0.1756886778 to 0.0.1762891276_ge61ff2
On Tue, 11 Nov 2025 at 17:32, Tiago de Paula <tiagodepalves@gmail.com> wrote:
On Tue, 11 Nov 2025 at 16:38, Giovanni Santini <giovannisantini93@yahoo.it> wrote:
Hello,
On 2025-11-10 21:58, Tiago de Paula wrote:
That `+` sign is not allowed in `pkgver`. See <https://wiki.archlinux.org/title/PKGBUILD#pkgver>:
It can contain letters, numbers, periods and underscores, but not a hyphen (-). If the author of the software uses one, replace it with an underscore (_).
I tried to replace the pluses with underscore, but still getting the same error:
```
(20:37) giovanni @ ~/Projects/AUR/wip/ampcode $ grep ^pkgver PKGBUILD pkgver="0.0.1762617680_gaa03ea" (20:37) giovanni @ ~/Projects/AUR/wip/ampcode $ cat .nvchecker.toml [ampcode] source = "npm" npm = "@sourcegraph/amp" from_pattern = '([0-9.]+)-([a-z0-9]+)' to_pattern = '\1_\2' (20:37) giovanni @ ~/Projects/AUR/wip/ampcode $ pkgctl version upgrade 📡 ampcode: query latest version ⌛ Upgrading: 1/1 [100%] ⠄⠀==> ERROR: Non-standard pkgver declaration
```
Is it a `pkgctl` bug?
-- Giovanni Santini
I can't reproduce this issue locally. Testing your `.nvchecker.toml` on the current `ampcode` from AUR, I get this instead:
```console
pkgctl version upgrade Failure x ampcode: failed to update checksums for version 0.0.1762891276_ge61ff2
Upgraded ! ampcode: upgraded from version 0.0.1756886778 to 0.0.1762891276_ge61ff2 ```
And then changing the PKGBUILD to use the NPM tarball (`source=("https://registry.npmjs.org/@sourcegraph/amp/-/amp-${pkgver/_/-}.tgz")`) does work for me:
```console
pkgctl version upgrade Upgraded ! ampcode: upgraded from version 0.0.1756886778 to 0.0.1762891276_ge61ff2
Actually, you are right. There's indeed an issue with `pkgctl`. I got the same error by adding quotes to `pkgver`: ```console $ pkgctl version upgrade 📡 ampcode: query latest version ⌛ Upgrading: 1/1 [100%] ◥==> ERROR: Non-standard pkgver declaration ``` It comes from <https://gitlab.archlinux.org/archlinux/devtools/-/blob/master/src/lib/util/pkgbuild.sh>. The regex `"^pkgver=${pkgver}$"` does not allow quotes, single or double.
participants (2)
-
Giovanni Santini
-
Tiago de Paula