You can use a pkgver function. Just look at one of these other *-git
PKGBUILDs
I already did. And for me it seems they update the PKGBUILD manually everytime? Or runs a cronjob or something on the AUR Server wich updates this automatic?
Nope, that would be to crazy ;). The âmagicâ is in the pkgver function in the PKGBUILD file which is dynamically creating the version number during build. Now AUR helpers like yay, for example store the last commit hash when you build the package and check that against the lasted commit hash in the remote git repository (if you enabled that in yayâŚ)
See: https://wiki.archlinux.org/title/VCS_package_guidelines for details.
edit ah, too late, @dalto beat me
Is this automatic enabled? Because i didnt changed anything in yay, and it updates any -git package i have installed.
You either do yay -Syu --devel
to check for repo package + AUR packages + AUR -git packages
or what you can do as well is to enable the --devel
(-git check) flag permanently with:
yay -Y --devel --save
That way, you just need to run yay
and itâll basic upgrade anything (like yay -Syu --devel
does).
Yeah ok. But i never do that this way.
I simply do yay -Syu. And didnt changed any configuration from yay.
And it updates packages if new commits are available (for a USB WLAN dongle for example on a other system from me). So they maintainer must it do it a another way?
Save yourself 4 keystrokesâŚall you need to type is yay.
hehe. I only wrote i do that. In reality i do yay -Syyu. But i dont wanted to trigger somebody
Well, yeah for ânormalâ (non -git) packages the maintainer has to update the version manually.
For -git it works this way:
- Check pkgver in .SRCINFO (in AUR) against the locally installed version â If newer â Rebuild/Upgrade package (this is how it works with normal packages as well)
- If the versions are the same, the commit hash check is performed as mentioned above.
You wonât trigger anyone but they will probably tell you it is totally unnecessary unless you changed mirrors or added a repo or something.
ok, so the maintainer from this package https://aur.archlinux.org/packages/rtl8821au-dkms-git/
updates the PKGBUILD manually. Because this package gets on my mentioned System reguarly updated, without any flags or options on my side.
Yeah. Im simply paranoid⌠Its a left over from gentoo times.
Yes, some maintainers might do that to make sure the people using his/her -git package are getting updates even when they do not use the e.g. ââdevelâ feature in yay. (I sometimes use to do this as well if I think âitâs worth itâ). A lot of people know donât about the --devel / VCS check thing soâŚ
Generally -git packages though are not being updated by the maintainer unless there are other changes to the PKGBUILD file other than the versionâŚ
He triggers me. Iâm operating a couple of mirrors and I donât want bandwidth to get wasted
Itâs purposely wasting your money every time they do that. Iâd be pissed.
Itâs a couple of VPSâs / root servers with a fixed price / month. Luckily traffic does not really matter (there is a certain threshold when bandwidth is being throttled, but Iâm still far away from that fortunately).
But yeah, if one doesnât know better, or if in doubt, okâŚ
If itâs really on purpose (like: âI want to generate useless trafficâ) â FU
Im sorry
As i worked today again after all the holidays, i just wanted to report that the import over cli worked flawlessy!
Thanks for the tip.