generated from actions/container-toolkit-action
-
Notifications
You must be signed in to change notification settings - Fork 36
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #54 from homoluctus/feature/update_deploy_flow
Update deployment flow
- Loading branch information
Showing
15 changed files
with
14,779 additions
and
5,520 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,8 +3,7 @@ name: TS Lint Check | |
on: | ||
pull_request: | ||
branches: | ||
- develop | ||
- releases/* | ||
- master | ||
paths: | ||
- src/* | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,86 +2,35 @@ name: Prepare for release | |
|
||
on: | ||
push: | ||
branches: | ||
- releases/* | ||
|
||
paths: | ||
- src/* | ||
tags: | ||
- 'v*' | ||
|
||
jobs: | ||
release: | ||
name: Build production | ||
runs-on: ubuntu-18.04 | ||
steps: | ||
- uses: actions/checkout@v1 | ||
with: | ||
ref: remotes/origin/releases/v1 | ||
|
||
- name: Git checkout | ||
run: git checkout -b releases/v1 | ||
|
||
- name: Setup Node | ||
uses: actions/setup-node@v1 | ||
- uses: actions/setup-node@v1 | ||
with: | ||
node-version: '10.x' | ||
|
||
- name: Install dependencies | ||
run: npm install | ||
|
||
- name: NPM build | ||
run: npm run build | ||
|
||
- name: Not ignore node_modules | ||
run: sed -i '/node_modules*/d' .gitignore | ||
|
||
- name: Install dependencies for production | ||
run: | | ||
rm -rf node_modules | ||
npm install --production | ||
- name: Setup git | ||
- name: Create Release | ||
uses: actions/[email protected] | ||
env: | ||
ACCESS_TOKEN: ${{ secrets.ACCESS_TOKEN }} | ||
run: | | ||
git config --local user.name homoluctus | ||
git config --local user.email [email protected] | ||
git remote set-url origin https://homoluctus:${ACCESS_TOKEN}@github.com/homoluctus/slatify.git | ||
- name: Git commit | ||
run: | | ||
git add -A | ||
DIFF=`git diff --cached --numstat | wc -l` | ||
if [ $DIFF -eq 0 ]; then | ||
exit 0 | ||
fi | ||
git commit -am '[UPDATE] prepare for release' | ||
- name: Git push | ||
run: git push origin HEAD | ||
|
||
- name: Slack Notification | ||
uses: homoluctus/slatify@master | ||
if: always() | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
with: | ||
type: ${{ job.status }} | ||
job_name: ':truck: *Prepare for release*' | ||
channel: '#develop' | ||
url: ${{ secrets.SLACK_WEBHOOK }} | ||
|
||
check: | ||
name: Check action | ||
runs-on: ubuntu-18.04 | ||
needs: release | ||
steps: | ||
- uses: actions/checkout@master | ||
tag_name: ${{ github.ref }} | ||
release_name: ${{ github.ref }} | ||
draft: 'false' | ||
prerelease: 'false' | ||
|
||
- name: Slack Notification | ||
uses: homoluctus/slatify@releases/v1 | ||
uses: homoluctus/slatify@master | ||
if: always() | ||
with: | ||
type: ${{ job.status }} | ||
job_name: ':robot_face: *Check action*' | ||
job_name: ':rocket: *Publish new release ${{ github.ref }}*' | ||
channel: '#develop' | ||
url: ${{ secrets.SLACK_WEBHOOK }} | ||
url: ${{ secrets.SLACK_WEBHOOK }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.