You are not logged in.

#1 2014-04-02 15:39:28

Zygote
Member
Registered: 2013-01-15
Posts: 75

[SOLVED] Best practice on updating git-sourced packages?

So quick question. Im maintaining an AUR package that grabs sources from git. How should I update the package? Will the package be automatically updated when the git repo has new commits, or do I have to manually increment the pkgrel variable in the PKGBUILD or is there something else I should be doing?

Cheers!

Last edited by Zygote (2014-04-03 07:04:44)

Offline

#2 2014-04-02 16:12:28

WorMzy
Forum Moderator
From: Scotland
Registered: 2010-06-16
Posts: 5,265

Re: [SOLVED] Best practice on updating git-sourced packages?

I think that's something I forgot to mention in your other thread -- write a pkgver function to update the PKGBUILD's pkgver. The wiki link I posted in that thread (about VCS PKGBUILD standards) has the details.

Regardless, when you run makepkg against a (correctly written) PKGBUILD, it pulls in the upstram changes and builds against them.


Sakura:-
Mobo: ASUS P8Z77-V PRO // Processor: Intel Core i7-3770K 3.4GHz // GFX: nVidia GeForce GTX 970 Ti // RAM: 32GB (4x 8GB) Corsair DDR3 (@ 2133MHz) // Storage: 1x 3TB Seagate SATAII 5x 1TB Samsung SATAII, 2x 120GB Corsair SSD

Online

#3 2014-04-02 16:50:33

drcouzelis
Member
From: Connecticut, USA
Registered: 2009-11-09
Posts: 3,475
Website

Re: [SOLVED] Best practice on updating git-sourced packages?

Zygote wrote:

Im maintaining an AUR package that grabs sources from git. How should I update the package?

As a maintainer, you shouldn't "update" anything. As long as the PKGBUILD file successfully builds the package then it's good!

Will the package be automatically updated when the git repo has new commits

No, it will not. There is nothing automatic about the AUR.

do I have to manually increment the pkgrel variable in the PKGBUILD or is there something else I should be doing?

Updating a package that relies on git is the responsibility of the end user.

As an end user, it's my responsibility to read the project's commit messages and mailing lists and bug reports, decide that the software is stable, and when I have enough time, run "makepkg" (or an AUR helper) to create a fresh new package based on the latest source code from the git repository.

Offline

#4 2014-04-02 16:59:47

Trilby
Forum Moderator
From: Massachusetts, USA
Registered: 2011-11-29
Posts: 13,812
Website

Re: [SOLVED] Best practice on updating git-sourced packages?

The only thing to add to the above is that the AUR package name should have -git appended to the name.  This makes it clear to users what they are getting and that it is up to them to make the choices mentioned above.  Apparently some AUR helpers even use these -git -dev type package names to rebuild everything for you with the right flags.


InterrobangSlider
• How's my coding? See this page.
• How's my moderating? Feel free to email any concerns, complaints, or objections.

Offline

#5 2014-04-03 06:33:37

Zygote
Member
Registered: 2013-01-15
Posts: 75

Re: [SOLVED] Best practice on updating git-sourced packages?

Thanks for all the input! Ive added a pkgver function and hopefully things are working well.

Offline

#6 2014-04-03 06:51:41

Zygote
Member
Registered: 2013-01-15
Posts: 75

Re: [SOLVED] Best practice on updating git-sourced packages?

Quick question. When is the pkgver run exactly? Currently, the package on AUR shows r40.6657d43. However, the source on github is currently at r42. Should I update the package on the AUR every now and then to reflect this or should I just leave it?

Offline

#7 2014-04-03 06:54:49

jasonwryan
Forum & Wiki Admin
From: .nz
Registered: 2009-05-09
Posts: 18,825
Website

Re: [SOLVED] Best practice on updating git-sourced packages?

Just leave it: it will be updated whenever someone downloads it and runs makepkg.


Arch + dwm   •   Mercurial repos  •   Github

Registered Linux User #482438

Offline

#8 2014-04-03 06:57:00

Zygote
Member
Registered: 2013-01-15
Posts: 75

Re: [SOLVED] Best practice on updating git-sourced packages?

jasonwryan wrote:

Just leave it: it will be updated whenever someone downloads it and runs makepkg.

Ah really? Thats awesome! Thanks!

Offline

#9 2014-04-03 07:02:57

jasonwryan
Forum & Wiki Admin
From: .nz
Registered: 2009-05-09
Posts: 18,825
Website

Re: [SOLVED] Best practice on updating git-sourced packages?

No problem. Please remember to mark your thread as [Solved] by editing your first post and prepending it to the title.


Arch + dwm   •   Mercurial repos  •   Github

Registered Linux User #482438

Offline

Board footer

Powered by FluxBB