Removing unwanted changes from git #17
Replies: 5 comments 9 replies
-
Beta Was this translation helpful? Give feedback.
-
Another simple idea might be a clever use of git. Here's how it would work: For the first PR:
For all subsequent PRs, you can:
If this seems promising, you can make it into a shell script so it's just one command to run each time you open a new PR. Try it out! Should be a lot less boilerplate than a VS Code extension. If it doesn't sound good, that's OK :) |
Beta Was this translation helpful? Give feedback.
-
new idea, generate branch by reverting ALL personal commits in dev branch. Instead of reverting 1 by 1, extract all personal commits (from actually I don't extract, I just add personal commit to branch to generate PR branch: but in this case I need to know which commits are personal BEFORE committing them. I found a solution: I can remove personal changes after, and STILL add them as commits to branch in branch or, instead of to do these steps: 2 extra branches take a bit of space |
Beta Was this translation helpful? Give feedback.
-
the above didn't work.. is there ANY way to mark a list of commits to drop when generating a PR branch ? I thought about ALWAYS starting personal commits with or tagging personal commits: but this would pollute my tag space: too many tags, I could but idk where to feature request to git, to add a way to mark commits. |
Beta Was this translation helpful? Give feedback.
-
found no better solution |
Beta Was this translation helpful? Give feedback.
-
I can't use .gitignore, because I want everything to be saved to remote,
if "git update-index --assume-unchanged" removes files from remote, that's not what I need
I'm currently trying to make a vscode extension to generate branch from branch using diffs I specify.
Beta Was this translation helpful? Give feedback.
All reactions