I have a project hosted on github. There is a main branch (main-branch) for the code that is deployed in production. Individual projects are branched from main (proj-001, proj-002...).
So in the course of a project/deploy....
- git checkout main-branch
- git pull origin main-branch
- git checkout -b proj-001
- (make some edits)
- git add .
- git commit -a -m "some notes"
- (merge the main-branch into my working branch)
- (make some more edits)
- git add .
- git commit -a -m "some more notes"
at some point the librarian pulls all of the code together for a test/deploy cycle. If there is a problem with a particular branch it is reverted. (and the bad news is that once it is reverted getting that branch back into the main-branch is difficult and risky.)
So my QUESTION: what is the best and easiest way to pull my commits into a new branch? (my current attempt to "cherry-pick" resulted in an error "fatal: Your index file is unmerged." which Google failed to describe.
UPDATE: I've updated the events... the librarian inadvertently merged the main-branch into my working branch... on more than one occasion.