Is any good way to work around patchs with git and Java imports?
I have a remote computer (the one I use at work), working with a branch called bugX
Now I’m at home, and I want a “copy” of that branch to my local computer to keep working.
So what I’ve done was to do a pull of the working copy in my local computer, and then I made a patch with the diffs of bugX branch against master in my remote computer, and then I tried to apply that patch to my local computer on branch master
But the patch keeps failing because the imports are all messed up.
[*] I’m not allowed to push the remote branch and then pull it from here.
EDIT:
I tried to make another branch from master (in the remote computer), and tryed to apply the patch to that branch and also failed.
If you have ssh access to your work computer from home, just add your work repo as a remote on your home pc and pull from there. And yes – you can pull from any git repo, “git servers” are not special in any way. Well they are bare which means they don’t have a working copy, but that is only relevant when pushing there.
If you don’t have ssh access to your work computer and are not allowed to push the branch to the central repo, I would recommend setting up a repo somewhere else (e.g. private git repo) and pushing there from work. Or you could just hide your branch on the server by pushing it there, but not as a proper branch (not in
refs/heads, but e.g.refs/hidden).