On local machine, create a feature branch via git checkout -b FEATURE_BRANCH_NAME
In case someone do not know how to add and commit files (like @kimonazj), use the following commands to add your code to local repo
Add any files under the current directory: git add .
Commit changes to repo: git commit -m "COMMENT_MSG"
In case you want to make changes to your commit, you can readd any files or remove them from stashed (git add) via git rm --cache PATH/TO/FILES
Then use git commit --amend to reset the commit and commit message
Note: do not use git commit --amend after you push to remote, doing so will result in some unpleasant issue
Finish the feature and any testing related to it (at least make sure it is compilable Okay?)
Push the feature branch to cloud via git push -u origin FEATURE_BRANCH_NAME and create a pull request with base as dev
If you complete a feature, please add [deploy] to commit message and create the pull request so that the change will be deployed to test server
Wait until me @William-An or @MARX1108 to review your code and permit the pull request, DO NOT authorize it by yourself unless you have told us in advance
First request me @William-An for coding standard
After @William-An finishes, he will request @MARX1108 for functionality check
After permit the pull request and merge it back to the dev branch, we will delete the remote feature branch
On your local machine, perform the following:
Checkout back to dev branch: git checkout dev
Sync with remote repo: git pull
Delete your local feature branch: git branch -d FEATURE_BRANCH_NAME
Repeat the process for new feature
For dev and main branches
Do not commit any feature on these two branches
The only allow commits are bug fixes or minor document changes as well as small portion code fix (less than 10 lines)
GitHub Action CI
Now we have set up a workflow for automatically test the backend and frontend and push the repo to remote server for deployment. The process of the workflow is as follows:
Branch introduction
Structure
main
anddev
branchdev
branchDevelopment cycle
git checkout -b FEATURE_BRANCH_NAME
git add .
git commit -m "COMMENT_MSG"
git add
) viagit rm --cache PATH/TO/FILES
git commit --amend
to reset the commit and commit messagegit commit --amend
after you push to remote, doing so will result in some unpleasant issuegit push -u origin FEATURE_BRANCH_NAME
and create a pull request with base asdev
[deploy]
to commit message and create the pull request so that the change will be deployed to test servergit checkout dev
git pull
git branch -d FEATURE_BRANCH_NAME
For
dev
andmain
branchesGitHub Action CI
Now we have set up a workflow for automatically test the backend and frontend and push the repo to remote server for deployment. The process of the workflow is as follows:
.coveragerc
NOT IMPLEMENTED
[deploy]
to actually deploy to test serverTODO