Skip to content

Conversation

@LukeHandle
Copy link
Contributor

@LukeHandle LukeHandle commented Jul 3, 2020

For some reason, there were issues with the normal ./audit.sh -u apache2buddy. Had to manually clean with git subrepo clean apache2buddy. Then the error appeared when running git subrepo pull apache2buddy, it showed the merge failed.

Not sure I've seen it fail there before. the audit script hid the messages which weren't great though.

Here was the error:

Details

$ git subrepo pull apache2buddy
The "git merge" command failed:
Auto-merging sha256sums.txt
CONFLICT (content): Merge conflict in sha256sums.txt
Auto-merging md5sums.txt
CONFLICT (content): Merge conflict in md5sums.txt
Auto-merging changelog
CONFLICT (content): Merge conflict in changelog
Auto-merging apache2buddy.pl
CONFLICT (content): Merge conflict in apache2buddy.pl
Automatic merge failed; fix conflicts and then commit the result.
You will need to finish the pull by hand. A new working tree has been
created at .git/tmp/subrepo/apache2buddy so that you can resolve the conflicts
shown in the output above.
This is the common conflict resolution workflow:

  1. cd .git/tmp/subrepo/apache2buddy
  2. Resolve the conflicts (see "git status").
  3. "git add" the resolved files.
  4. git commit
  5. If there are more conflicts, restart at step 2.
  6. cd /Users/luke8639/Projects/rackerlabs-useful-scripts
  7. git subrepo commit apache2buddy
    See "git help merge" for details.
    Alternatively, you can abort the pull and reset back to where you started:
  8. git subrepo clean apache2buddy
    See "git help subrepo" for more help.

$ echo $?
1

I couldn't get the "rebase" flags to work (eg. git subrepo pull -M rebase apache2buddy) so I did the steps manually per docs.

$ git subrepo clean apache2buddy
Removed branch 'subrepo/apache2buddy'.

$ git subrepo fetch apache2buddy
Fetched 'apache2buddy' from 'https://github.com/richardforth/apache2buddy.git' (staging).

$ git subrepo branch apache2buddy
Created branch 'subrepo/apache2buddy' and worktree '.git/tmp/subrepo/apache2buddy'.

$ git rebase subrepo/apache2buddy/fetch subrepo/apache2buddy
First, rewinding head to replay your work on top of it...

[...I seemed to end up on a diff rbanch here, not sure if user error...]

$ git subrepo commit apache2buddy
git-subrepo: Can't 'commit' while subrepo branch is checked out.

$ git checkout apache2buddy-update-2020-07-03
Switched to branch 'apache2buddy-update-2020-07-03'

$ git subrepo commit apache2buddy
Subrepo commit 'subrepo/apache2buddy' committed as
subdir 'apache2buddy/' to branch 'apache2buddy-update-2020-07-03'.

$ git push

And it verifies:

$ ./audit.sh -v apache2buddy

------------------------------------------
Verifying recorded commit...

Commit on file: 2629efffe39c356f254c05e760a3976a54be75d0
https://raw.githubusercontent.com/rackerlabs/useful-scripts/apache2buddy-update-2020-07-03/apache2buddy/.gitrepo

\e[4mRemote Repo Info (commit)\e[24m
https://raw.githubusercontent.com/richardforth/apache2buddy/2629efffe39c356f254c05e760a3976a54be75d0/apache2buddy.pl
sha1sum: d8e88d33755b2d3cd62b5ae3f1484237b2df62fa

\e[4mSubRepo (remote) Info (apache2buddy-update-2020-07-03)\e[24m
https://raw.githubusercontent.com/rackerlabs/useful-scripts/apache2buddy-update-2020-07-03/apache2buddy/apache2buddy.pl
sha1sum: d8e88d33755b2d3cd62b5ae3f1484237b2df62fa

Verifying commit: sha1sums match!
apache2buddy-update-2020-07-03 (remote branch) is inline with specified commit hash
------------------------------------------

subrepo:
  subdir:   "apache2buddy"
  merged:   "2629eff"
upstream:
  origin:   "https://github.com/richardforth/apache2buddy.git"
  branch:   "staging"
  commit:   "2629eff"
git-subrepo:
  version:  "0.4.1"
  origin:   "???"
  commit:   "???"
@LukeHandle LukeHandle requested a review from richardforth as a code owner July 3, 2020 11:18
@LukeHandle LukeHandle changed the title git subrepo commit apache2buddy Update apache2buddy to 2629efffe39c356f254c05e760a3976a54be75d0 Jul 3, 2020
@LukeShirnia LukeShirnia self-requested a review July 3, 2020 12:03
@LukeShirnia LukeShirnia merged commit 23f2210 into master Jul 3, 2020
@LukeShirnia LukeShirnia deleted the apache2buddy-update-2020-07-03 branch July 3, 2020 12:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants