Vote count:
0
I'm working with two branches in a git repository.
They are rc and dev.
I have a folder in dev src/ that I need to merge into rc.
I've tried to use git cherry-pick --strategy=recurisve --strategy-option=theirs <commit> method by first creating a shell script to add a new line to all the files in the directory to trigger a change with git.
The script was as follows:
#/bin/sh
SEARCH_FOLDER="src/*"
for f in $(find $SEARCH_FOLDER);
do
echo "" >> $f;
done;
What I did not realize is that git cherry-pick is only going to take the recognized changes vis-a-vis the aforementioned newlines.
Aside from just copying the folder over into a branch of rc and then creating a commit and merging, what are my options to push my changes that I've been working on in dev for two weeks into the rc branch.
I understand that the way I have been developing and using git is probably inappropriate and not intended use.
Ideally, I'd like to create a patch file using the diff on the two branches subfolders src/ and apply it. Though, I'm not sure how to execute this approach.
Merge folder from one branch into another with git
Aucun commentaire:
Enregistrer un commentaire