0.0.12 • Published 6 years ago
git-cherry-fix v0.0.12
git-cherry-fix
helps you get your fixes to another branch by cherry-picking them
Installation
npm install -g git-cherry-fixUsage
start interactive process
git-cherry-fixquick interactive process
git-cherry-fix <base-branch>Assumptions
In order for the quick-pr tool to work best, you should name your branches with a prefix and a forward slash.
So for example task/this-is-my-branch.
quick-pr uses this to know where your branch name starts, and uses the same convention by prefixing patch branches with patch/TARGET-task/this-is-my-branch. Where target is the target branch.
Examples
I just wrote a hotfix to master. Now I want to port it to staging and develop.
- I use branch name
patch/MASTER-task/fix-something - I run the command
git-cherry-fix staging- This will automatically create branch
patch/STAGING-task/fix-somethingbased off staging
- This will automatically create branch
- I run the command
git-cherry-fix develop- This will automatically create branch
task/fix-somethingbased off develop
- This will automatically create branch
Configuration
The following configuration is available in a file called .git-cherry-fix.yml.
We will look for the file upwards.
main_branch: develop
branch_nickname:
master: production
staging: qa- main_branch - defaults to
develop. will remove the prefix from the target branch if main_branch. for example, cherry picking frompatch/branch-fix/somethingtodevelopwill automatically make the branch name simplyfix/something(without a prefix). - branch_nickname - will use the nickname on the target branch name prefix. for example
patch/production-fix/something.
roadmap:
- push changes
open a PR (support bitbucket) - when applicable using base branch- Use quick-pr instead- allow configuration for different standards used than default
- show only commits that do not exist in target branch