Balm Git Flow
The best practices for front-end git flow
Workflow
- main(source code) -> dev(feat, fix...) -> prod(test, pre-production...)
- main(source code) -> prod(production)
Requirements
- Node.js >=12.20.0 (>=14.18.0 on Windows)
- Git 2.6.0+
Installation
npm install -g balm-git-flow
⚠️ NOTE: For Windows users, use npm install -g balm-git-flow@legacy
Configuration
First, create a balm.env.js
file in your project root directory (use balm-git doctor
)
Variable Name | Type | Description |
---|
BALM_GIT_FLOW_MAIN | string | main branch |
BALM_GIT_FLOW_RELEASE | string | production release branch |
BALM_GIT_FLOW_RELEASES | array | all release branches |
BALM_GIT_FLOW_SCRIPTS | array | all build scripts corresponding to the release branches |
BALM_GIT_FLOW_BUILD_DIR | string | build out dir |
Usage
balm-git doctor
: check the project environmentbalm-git dev <new-branch> [<start-point>]
: create new branch for development from origin main branchbalm-git prod
: release process
⚠️ NOTE: For Windows users, use balm-git-doctor
, balm-git-dev
and balm-git-prod