Gentoo Archives: gentoo-user

From: Alexander Kapshuk <alexander.kapshuk@×××××.com>
To: Gentoo mailing list <gentoo-user@l.g.o>
Subject: Re: [gentoo-user] Can't emerge --sync
Date: Sat, 15 Jul 2017 10:23:25
Message-Id: CAJ1xhMViGXq5n-RByhpUJQDEcWtMHk78THjMZMGvSkLngTzYwQ@mail.gmail.com
In Reply to: [gentoo-user] Can't emerge --sync by Peter Humphrey
1 On Sat, Jul 15, 2017 at 1:00 PM, Peter Humphrey <peter@××××××××××××.uk> wrote:
2 > Hello list,
3 >
4 > Today I get this:
5 >
6 > # emerge --sync
7 >>>> Syncing repository 'gentoo' into '/usr/portage'...
8 > /usr/bin/git pull
9 > remote: Counting objects: 25, done.
10 > remote: Compressing objects: 100% (9/9), done.
11 > remote: Total 25 (delta 15), reused 25 (delta 15), pack-reused 0
12 > Unpacking objects: 100% (25/25), done.
13 > From https://github.com/gentoo-mirror/gentoo
14 > c80ef88a736..b9cb9e0b42e stable -> origin/stable
15 > Updating c5ec29f674c..b9cb9e0b42e
16 > error: Your local changes to the following files would be overwritten by
17 > merge:
18 > metadata/layout.conf
19 > Please commit your changes or stash them before you merge.
20 > Aborting
21 > !!! git pull error in /usr/portage
22 >
23 > I can't imagine I'd ever make any changes to that file, especially not using
24 > git, but I tried reverting to backups of /var and /usr/portage from a week
25 > ago, but I still get the same error. Using backups from two weeks ago also
26 > made no difference.
27 >
28 > I sync and update every day, with never a problem like this before.
29 >
30 > Can anyone see what else I should try? Should I just delete the offending
31 > file? (I'll get some coffee meanwhile...)
32 >
33 > --
34 > Regards
35 > Peter
36 >
37 >
38 git-checkout(1) has a '--theirs' option that might do the trick there:
39
40 The index may contain unmerged entries because of a previous failed
41 merge. By default, if you try to check out such an entry from the
42 index, the checkout operation will fail and nothing will be checked
43 out.
44 ...
45 You could try:
46 git checkout --theirs metadata/layout.conf