Skip to content

Commit

Permalink
build: implement scheduled release (#603)
Browse files Browse the repository at this point in the history
  • Loading branch information
exKAZUu authored Jun 20, 2021
1 parent da02469 commit d80f2e2
Show file tree
Hide file tree
Showing 3 changed files with 37 additions and 7 deletions.
33 changes: 33 additions & 0 deletions .github/workflows/semantic-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: Release

on:
schedule:
- cron: '0 5 * * 0'

jobs:
semantic-release:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Generate dot env
run: |
echo '${{ secrets.DOT_ENV }}' > .env
- name: Read version files
run: |
echo "NODE_VERSION=$(cat .node-version)" >> $GITHUB_ENV
- uses: actions/setup-node@v2
with:
node-version: ${{ env.NODE_VERSION }}
- name: Show environment information
run: |
echo "node: $(node -v)"
echo "yarn: $(yarn -v)"
- uses: actions/cache@v2
with:
path: .yarn
key: ${{ runner.os }}-yarn-${{ hashFiles('yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- run: yarn install
- run: yarn build
- run: yarn release
8 changes: 2 additions & 6 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Test & Release
name: Test

on:
pull_request:
Expand All @@ -23,7 +23,7 @@ jobs:
skip_after_successful_duplicate: true
concurrent_skipping: always
paths_ignore: '["**/*.md", "**/docs/**"]'
test-and-release:
test:
needs: pre
if: ${{ needs.pre_job.outputs.should_skip != 'true' }}
runs-on: ubuntu-latest
Expand All @@ -49,7 +49,3 @@ jobs:
- run: yarn typecheck
- run: yarn lint
- run: yarn build
- run: |
echo '${{ secrets.DOT_ENV }}' > .env
yarn release
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/main' }}
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# PlantUML Visualizer

[![Test & Release](https://github.com/WillBooster/plantuml-visualizer/actions/workflows/test.yml/badge.svg)](https://github.com/WillBooster/plantuml-visualizer/actions/workflows/test.yml)
[![Test](https://github.com/WillBooster/plantuml-visualizer/actions/workflows/test.yml/badge.svg)](https://github.com/WillBooster/plantuml-visualizer/actions/workflows/test.yml)
[![Release](https://github.com/WillBooster/plantuml-visualizer/actions/workflows/semantic-release.yml/badge.svg)](https://github.com/WillBooster/plantuml-visualizer/actions/workflows/semantic-release.yml)
[![semantic-release](https://img.shields.io/badge/%20%20%F0%9F%93%A6%F0%9F%9A%80-semantic--release-e10079.svg)](https://github.com/semantic-release/semantic-release)

:factory: A Chrome / Firefox extension for visualizing PlantUML descriptions.
Expand Down

0 comments on commit d80f2e2

Please sign in to comment.