File tree Expand file tree Collapse file tree 3 files changed +19
-10
lines changed
Expand file tree Collapse file tree 3 files changed +19
-10
lines changed Original file line number Diff line number Diff line change 3131 COMMIT_NAME=" ${GITHUB_ACTOR} "
3232fi
3333
34- # Directs the action to the the Github workspace.
3534cd $GITHUB_WORKSPACE && \
3635
37- # Configures Git.
3836git init && \
3937git config --global user.email " ${COMMIT_EMAIL} " && \
4038git config --global user.name " ${COMMIT_NAME} " && \
4139
4240
43- # # Initializes the repository path using the access token.
4441REPOSITORY_PATH=" https://${ACCESS_TOKEN} @github.com/${GITHUB_REPOSITORY} .git" && \
4542
43+ git checkout " ${BASE_BRANCH:- master} "
4644
47- # Builds the project if a build script is provided.
4845echo " -----------------------Running build scripts... ---------------"
4946
5047eval " $BUILD_SCRIPT " && \
Original file line number Diff line number Diff line change 1818 COMMIT_EMAIL : jeoy_z@126.com
1919 COMMIT_NAME : jeoy
2020 ACCESS_TOKEN : ${{ secrets.ACCESS_TOKEN }}
21- BASE_BRANCH : master # The branch the action should deploy from.
22- # DEPLOY_BRANCH: gh-pages # The branch the action should deploy to.
23- FOLDER : build # The folder the action should deploy.
24- BUILD_SCRIPT : yarn && yarn build # The build script the action should run prior to deploying.
21+ BASE_BRANCH : master # The branch you want to build
22+ DEPLOY_BRANCH : gh-pages # The branch you want to deploy
23+ BUILD_SCRIPT : yarn && yarn build # The build script
24+ FOLDER : build # The folder generated by build script
25+
Original file line number Diff line number Diff line change 1- ### This action will auto deploy to target branch when it get triggered
1+ # Github-deploy-actions
2+
3+ This action will auto deploy to target branch when it get triggered
4+
5+ # How It Works
26
37When push to ` master ` branch
48
@@ -8,4 +12,11 @@ Then push `build` folder as a new commit on `gh-pages` branch
812
913> note: mark sure ` build ` folder is on your gitignore list
1014
11- deploy page: [ demo] ( https://jeoy.github.io/github-deploy-actions/ )
15+ # deploy page:
16+
17+ [ demo] ( https://jeoy.github.io/github-deploy-actions/ )
18+
19+ ## what exactly is done during the action
20+
21+ checkout this
22+ [ shell] ( https://github.com/jeoy/github-deploy-actions/blob/develop/.github/actions/deploy/entrypoint.sh )
You can’t perform that action at this time.
0 commit comments