You are not logged in.

#1 2019-06-15 13:29:56

mipi
Member
From: Germany
Registered: 2018-01-03
Posts: 35

[SOLVED] Cloning of Github repos by makepkg

Hi,
I do not understand under which circumstances a Github (or Gitlab or Bitbucket etc.) repo is cloned by makepkg.

(1) I created AUR packages for some of the tools that I had written. In the PKGBUILDs, the source array contains the url of the Github repo, and the repo is cloned by makepkg. It seems that this happens automatically since I did not do an explicite git clone in the PKGBUILD.

(2) I am currently working on a Calamares-based installer for Arch. As part of this effort, I am packaging Calamares. The url of the Calamares Github repo is contained in the source array of the PKGBUILD, but the repo is not cloned automatically (and so, I do this explicitely in the prepare() function).

I don't understand the different behavior of makepkg in the cases (1) and (2). Can anybody explain?

Thanks,
mipi

Last edited by mipi (2019-06-15 14:02:59)

Offline

#2 2019-06-15 13:37:02

graysky
Wiki Maintainer
From: :wq
Registered: 2008-12-01
Posts: 9,776
Website

Re: [SOLVED] Cloning of Github repos by makepkg

Show the source array for 1 and 2.


CPU-optimized Linux-ck packages @ Repo-ck  • AUR packagesZsh and other configs

Offline

#3 2019-06-15 13:41:03

mipi
Member
From: Germany
Registered: 2018-01-03
Posts: 35

Re: [SOLVED] Cloning of Github repos by makepkg

Source arrays:

(1): source=("git://github.com/mipimipi/$_pkgname.git")

(2): source=("https://github.com/calamares/calamares.git")

Offline

#4 2019-06-15 13:43:51

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 21,708
Website

Re: [SOLVED] Cloning of Github repos by makepkg


"UNIX is simple and coherent..." - Dennis Ritchie, "GNU's Not UNIX" -  Richard Stallman

Online

#5 2019-06-15 13:51:37

mipi
Member
From: Germany
Registered: 2018-01-03
Posts: 35

Re: [SOLVED] Cloning of Github repos by makepkg

@Trilby: Thanks for the link. But why isn't the repo cloned in case (2)? the url is compatible to the format that is described in the documentation.

Offline

#6 2019-06-15 13:55:48

WorMzy
Forum Moderator
From: Scotland
Registered: 2010-06-16
Posts: 8,867
Website

Re: [SOLVED] Cloning of Github repos by makepkg

No, it isn't.

wiki wrote:
  • vcs+ is needed for URLs that do not reflect the VCS type, e.g. git+http://some_repo.


Sakura:-
Mobo: MSI X299 TOMAHAWK ARCTIC // Processor: Intel Core i7-7820X 3.6GHz // GFX: nVidia GeForce GTX 970 // RAM: 32GB (4x 8GB) Corsair DDR4 (@ 3000MHz) // Storage: 1x 3TB HDD, 5x 1TB HDD, 2x 120GB SSD, 1x 275GB M2 SSD

Making lemonade from lemons since 2015.

Offline

#7 2019-06-15 14:02:21

mipi
Member
From: Germany
Registered: 2018-01-03
Posts: 35

Re: [SOLVED] Cloning of Github repos by makepkg

Yep, that was it. Cloning works also in case (2) if I replace "https" by "git+http".
Thanks.

Offline

#8 2019-06-15 14:24:01

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 21,708
Website

Re: [SOLVED] Cloning of Github repos by makepkg

or "git+https://" or "git://" would work.  No specific form is needed, but if the url protocol itself doesn't indicate what downloader to use, you need to specify it before a "+".


"UNIX is simple and coherent..." - Dennis Ritchie, "GNU's Not UNIX" -  Richard Stallman

Online

Board footer

Powered by FluxBB