Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable downloading build files using git #346

Closed
wants to merge 3 commits into
base: master
from

Conversation

Projects
None yet
5 participants
@markusgrosser
Copy link
Contributor

markusgrosser commented Aug 22, 2015

This adds a flag that enables downloading of build files (PKGBUILD, .install etc.) using git, which was made possible with AUR4.

While this currently doesn't give any benefit over the old method of downloading a tarball*, it is intended to serve as a baseline for possible future changes, like using git for diffs.

It also adds hlibgit2 as a dependency, which currently doesn't have an AUR package. I'm willing to create and maintain one (as well as dependencies), should this get merged.

As a useless side effect, this makes aura the first AUR Helper to have all features in the AUR Helper comparison table.

 

*In fact, this just downloads more data since it needs to fetch the complete history.

markusgrosser added some commits Aug 22, 2015

Add --use-git/-g Flag
This commit adds a flag telling aura to use git clone to download
PKGBUILDs for building packages and adds a corresponding setting.

Note that this does not actually add said functionality to aura, but
only the flag to use as a baseline for possible implementations (using
either CLI or calling libgit directly).
Download build files using libgit2
When the --use-git/-g flag is given, use the clone functionality from
libgit2 to fetch build files, instead of downloading a tarball.
@fosskers

This comment has been minimized.

Copy link
Member

fosskers commented Aug 27, 2015

If we're going to do this, let's just make it the default.

@flamusdiu

This comment has been minimized.

Copy link

flamusdiu commented Aug 27, 2015

@fosskers I would have to agree. All the AUR packages are going to be in a git repo anyway. It would support better downloading too.

Download using git by default
Aura now always downloads build files using git. This removes the
-g/--use-git flag.
@fosskers

This comment has been minimized.

Copy link
Member

fosskers commented Oct 3, 2015

How does this affect -Aw? Will it just clone the repo to the pwd?

@fosskers

This comment has been minimized.

Copy link
Member

fosskers commented Nov 19, 2015

@markusgrosser , I just checked Hackage and there are quite a few git packages. What was the motivation for choosing the one you did?

@markusgrosser

This comment has been minimized.

Copy link
Contributor Author

markusgrosser commented Nov 19, 2015

The main reasons were feature-completeness and documentation, in which gitlib was (and still is) sadly lacking.

libgit (not to be confused with libgit2 which is the C library) might be an alternative, but it's only a wrapper around the git executable, whereas I personally preferred a "native" implementation.

I didn't see hit when I initially searched for a git library, but it seems like a good alternative, which I'll definitely look into. It doesn't support cloning though, so that'll probably have to be done by calling git clone ... directly.

Regarding -Aw, it seems to not do … anything, which I can't say I really understand. Cloning into $PDW/$pkgname seems like a sane choice though, so I'll probably implement that.

@fosskers

This comment has been minimized.

Copy link
Member

fosskers commented Nov 19, 2015

git

gitlib was the main one I looked at, but was fairly quickly turned off by it. The main things we're looking for are cloning and the ability to branch, to be able to hotedit PKGBUILDs.

Cloning into $PDW/$pkgname seems like a sane choice

I agree, that's the end result of what -Aw does, after you've untar'd the file it downloads.

@DuncanvR

This comment has been minimized.

Copy link
Contributor

DuncanvR commented Aug 6, 2017

@markusgrosser

*In fact, this just downloads more data since it needs to fetch the complete history.

Not sure how this is achieved using hlibgit2, but on the command line you can use the --depth argument to control the amount of history that's fetched. E.g. git clone --depth 1 https://github.com/aurapm/aura.git only retrieves the last commit -- but still with all files in place.

@fosskers fosskers referenced this pull request May 30, 2018

Merged

Aura 2.0 #479

12 of 12 tasks complete

@fosskers fosskers closed this Jun 26, 2018

@AladW

This comment has been minimized.

Copy link
Contributor

AladW commented Jul 23, 2018

Impressive work on Aura 2.0! The wiki entry for aura should probably be updated...

@AladW

This comment has been minimized.

Copy link
Contributor

AladW commented Jul 23, 2018

Or I'll wait until the AUR pkgver is bumped: #489

@fosskers

This comment has been minimized.

Copy link
Member

fosskers commented Jul 24, 2018

The README has been updated, but both Aura's wiki entry on the Arch wiki and the AUR helpers chart need to be updated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.