Gentoo Archives: gentoo-user

From: Bryan Gardiner <bog@××××××.net>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] Layman and Git branch
Date: Thu, 16 Jun 2016 18:55:35
Message-Id: 20160616115515.4a1580b6@khumba.net
In Reply to: Re: [gentoo-user] Layman and Git branch by Bryan Gardiner
1 On Thu, 16 Jun 2016 11:46:12 -0700
2 Bryan Gardiner <bog@××××××.net> wrote:
3
4 > On Thu, 16 Jun 2016 17:52:26 +0200
5 > marco@×××××××.it wrote:
6 >
7 > > Hi,
8 > > i have a layman git profile to store my stuff.
9 > >
10 > > Is possible to force layman -S to sync a specific branch ?
11 >
12 > This is speculation (and a bit of looking at Portage code), since I
13 > haven't tried this. Ignoring Layman, repos.conf repositories support
14 > syncing[1], so does it work to create:
15 >
16 > /etc/portage/repos.conf/myrepo.conf:
17 >
18 > [myrepo]
19 > location = /path/to/local/repo
20 > sync-type = git
21 > sync-uri = git://...
22 > auto-sync = yes
23 >
24 > and just emerge --sync? If you didn't have the local repo already
25 > then it would clone and use master, but I suspect that you can switch
26 > branches afterward, and Portage will simply call "git pull".
27 >
28 > There also seem to be extra options "sync-git-clone-extra-opts" and
29 > "sync-git-pull-extra-opts" for git modules, so you might be able to
30 > set:
31 >
32 > sync-git-clone-extra-opts = --branch somebranch
33 >
34 > to fix initially checking out master.
35 >
36 > HTH,
37 > Bryan
38 >
39 > [1] https://wiki.gentoo.org/wiki/Project:Portage/Sync
40
41 If you're set on using Layman though, does Layman switch back to master
42 on every sync, or is it the initial checkout you're concerned about?
43 Or just a convenience to have Layman switch branches?
44
45 - Bryan
46
47 --
48 khph - file tagging via symlinks