standardebooks / thomas-bulfinch_bulfinchs-mythology

Epub source for the Standard Ebooks edition of Bulfinch’s Mythology, by Thomas Bulfinch
https://standardebooks.org/ebooks/thomas-bulfinch/bulfinchs-mythology
Other
2 stars 2 forks source link

Fix glossary #3

Closed drgrigg closed 3 years ago

drgrigg commented 4 years ago

Alex: This was a lot of work. I hope I've done it correctly. The main thing is that the existing glossary was a mess (not really surprising given that it started out as an index). So I've cleaned it up quite a bit and I've now removed all instances of "See XXXX" and "XXXX (which see)" and hyperlinked the referenced word instead.

acabal commented 4 years ago

Excellent work David, I think this is basically good to go. Can you just rebase against master to fix the merge conflict? It's in content.opf due to the new se.css file added today.

drgrigg commented 4 years ago

Alex:

I’m in a world of pain with this rebasing business (my git knowledge is limited, I’m afraid).

I’m using Github Desktop and it's now telling me that if I go ahead I will have to force-push and it warns me:

“A force push will rewrite history on origin/fixgloss. Any collaborators working on this branch will need to reset their own local branch to match the history of the remote."

Is it OK to go ahead with this?

Regards,

David On 11 Sep 2020, 5:30 AM +1000, Alex Cabal notifications@github.com, wrote:

Excellent work David, I think this is basically good to go. Can you just rebase against master to fix the merge conflict? It's in content.opf due to the new se.css file added today. — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

acabal commented 4 years ago

On the command line, switch to master and do git pull to get the latest changes. Then, switch to the glossary branch and do git rebase master.

You should only have one easy conflict, in content.opf. If other files are conflicting then something went wrong. Once you're done rebasing, git push -f and that should be it.

acabal commented 4 years ago

David before you continue I don't think you rebased this right. It looks like you did some kind of merge commit or something, which indicates you changed 88 files which can't be right. You should abandon the rebase and try again. You can always recover from a tough state using the reflog--just google how to undo a merge commit, or undo a rebase. I suggest you not use a gui for any of this, the basic task of rebasing onto master is a simple CLI three-liner.

acabal commented 4 years ago

Once you recover back to the pre-rebase state, this is what you do:

cd /path/to/repo git checkout master git pull --rebase # Get the latest changes from Github master git checkout fixgloss git rebase master # Rebase your local branch onto the fetched changes git push -f # Force push back up to your Github branch

acabal commented 4 years ago

Forgot to mention, in the above instructions after you do git rebase master, it will inform you of conflicts. To fix them, do git mergetool which should open some kind of merge GUI. If not you can find out how to configure a merge GUI with git online, or complete the merge by hand which is more complicated, but on the other hand this is the simplest possible merge conflict resolution. Just one line in one file.

drgrigg commented 4 years ago

Alex:

I’ve tried it both ways, both command line and GitHub Desktop. This is the story on the command line:

david@MacBook-Pro-3 ~/O/S/T/thomas-bulfinch_bulfinchs-mythology (master)> git checkout fixgloss Branch 'fixgloss' set up to track remote branch 'fixgloss' from 'origin'. Switched to a new branch 'fixgloss' david@MacBook-Pro-3 ~/O/S/T/thomas-bulfinch_bulfinchs-mythology (fixgloss)> git fetch origin david@MacBook-Pro-3 ~/O/S/T/thomas-bulfinch_bulfinchs-mythology (fixgloss)> git rebase origin/master First, rewinding head to replay your work on top of it... Applying: Updated to new glossary standard Applying: Ran clean Applying: Updated content.opf Using index info to reconstruct a base tree... M src/epub/content.opf Falling back to patching base and 3-way merge... Auto-merging src/epub/content.opf CONFLICT (content): Merge conflict in src/epub/content.opf error: Failed to merge in the changes. Patch failed at 0003 Updated content.opf Use 'git am --show-current-patch' to see the failed patch

Resolve all conflicts manually, mark them as resolved with "git add/rm ", then run "git rebase --continue". You can instead skip this commit: run "git rebase --skip". To abort and get back to the state before "git rebase", run "git rebase --abort".

AT THIS POINT I MANUALLY RESOLVED THE CONFLICT IN CONTENT.OPF:

david@MacBook-Pro-3 ~/O/S/T/thomas-bulfinch_bulfinchs-mythology (fixgloss|REBASE 3/10) [128]> git add src/epub/content.opf david@MacBook-Pro-3 ~/O/S/T/thomas-bulfinch_bulfinchs-mythology (fixgloss|REBASE 3/10) [1]> git rebase continue

It seems that there is already a rebase-apply directory, and I wonder if you are in the middle of another rebase. If that is the case, please try git rebase (--continue | --abort | --skip) If that is not the case, please rm -fr "/Users/david/OneDrive/Standard Ebooks/TEMP/thomas-bulfinch_bulfinchs-mythology/.git/rebase-apply" and run me again. I am stopping in case you still have something valuable there. david@MacBook-Pro-3 ~/O/S/T/thomas-bulfinch_bulfinchs-mythology (fixgloss|REBASE 3/10) [1]> rm -fr "/Users/david/OneDrive/Standard Ebooks/TEMP/thomas-bulfinch_bulfinchs-mythology/.git/rebase-apply" david@MacBook-Pro-3 ~/O/S/T/thomas-bulfinch_bulfinchs-mythology ((7eba66bf…))> git rebase continue fatal: Needed a single revision invalid upstream 'continue' david@MacBook-Pro-3 ~/O/S/T/thomas-bulfinch_bulfinchs-mythology ((7eba66bf…)) [1]>david@MacBook-Pro-3 ~/O/S/T/thomas-bulfinch_bulfinchs-mythology (master)> git checkout fixgloss Branch 'fixgloss' set up to track remote branch 'fixgloss' from 'origin'. Switched to a new branch 'fixgloss' david@MacBook-Pro-3 ~/O/S/T/thomas-bulfinch_bulfinchs-mythology (fixgloss)> git fetch origin david@MacBook-Pro-3 ~/O/S/T/thomas-bulfinch_bulfinchs-mythology (fixgloss)> git rebase origin/master First, rewinding head to replay your work on top of it... Applying: Updated to new glossary standard Applying: Ran clean Applying: Updated content.opf Using index info to reconstruct a base tree... M src/epub/content.opf Falling back to patching base and 3-way merge... Auto-merging src/epub/content.opf CONFLICT (content): Merge conflict in src/epub/content.opf error: Failed to merge in the changes. Patch failed at 0003 Updated content.opf Use 'git am --show-current-patch' to see the failed patch

Resolve all conflicts manually, mark them as resolved with "git add/rm ", then run "git rebase --continue". You can instead skip this commit: run "git rebase --skip". To abort and get back to the state before "git rebase", run "git rebase --abort".

david@MacBook-Pro-3 ~/O/S/T/thomas-bulfinch_bulfinchs-mythology (fixgloss|REBASE 3/10) [128]> git add src/epub/content.opf david@MacBook-Pro-3 ~/O/S/T/thomas-bulfinch_bulfinchs-mythology (fixgloss|REBASE 3/10) [1]> git rebase continue

It seems that there is already a rebase-apply directory, and I wonder if you are in the middle of another rebase. If that is the case, please try git rebase (--continue | --abort | --skip) If that is not the case, please rm -fr "/Users/david/OneDrive/Standard Ebooks/TEMP/thomas-bulfinch_bulfinchs-mythology/.git/rebase-apply" and run me again. I am stopping in case you still have something valuable there. david@MacBook-Pro-3 ~/O/S/T/thomas-bulfinch_bulfinchs-mythology (fixgloss|REBASE 3/10) [1]> rm -fr "/Users/david/OneDrive/Standard Ebooks/TEMP/thomas-bulfinch_bulfinchs-mythology/.git/rebase-apply" david@MacBook-Pro-3 ~/O/S/T/thomas-bulfinch_bulfinchs-mythology ((7eba66bf…))> git rebase continue fatal: Needed a single revision invalid upstream 'continue'

I’ve tried re-cloning the repository and starting afresh, but this is where I always end up.

Regards,

David On 11 Sep 2020, 11:56 AM +1000, Alex Cabal notifications@github.com, wrote:

Once you recover back to the pre-rebase state, this is what you do: cd /path/to/repo git checkout master git pull --rebase # Get the latest changes from Github master git checkout fixgloss git rebase master # Rebase your local branch onto the fetched changes git push -f # Force push back up to your Github branch — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

acabal commented 4 years ago

When you continue a rebase, you must do git rebase --continue not git rebase continue.

Git thinks you wish to start another rebase on the continue branch which is incorrect.

drgrigg commented 4 years ago

OK, thanks. Sorry to be so stupid. I’m still trying to get back to where I was before I started.

Regards,

David On 11 Sep 2020, 12:25 PM +1000, Alex Cabal notifications@github.com, wrote:

When you continue a rebase, you must do git rebase --continue not git rebase continue. Git thinks you wish to start another rebase on the continue branch which is incorrect. — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.