Skip to content

Commit

Permalink
fix: Missing package.json for semantic release
Browse files Browse the repository at this point in the history
  • Loading branch information
Fgruntjes committed Feb 1, 2023
1 parent 74ceb50 commit a3241b3
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 2 deletions.
37 changes: 37 additions & 0 deletions .github/workflows/deploy_release.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: Deploy release

on:
release:
types: [ published ]

jobs:
deploy_slug:
runs-on: ubuntu-latest
steps:
- uses: booxmedialtd/ws-action-parse-semver@v1
id: semver
with:
input_string: ${{ github.ref }}
version_extractor_regex: "\/v(.*)$"
- id: environment
run: PRERELASE=${{ steps.semver.outputs.prerelease }} echo "var=$([ -z "${PRERELASE}" ] && echo "production" || echo "${PRERELASE}")" >> $GITHUB_OUTPUT
outputs:
environment: ${{ steps.environment.outputs.var }}
tag: v${{ steps.semver.outputs.fullversion }}

build:
needs: [ deploy_slug ]
uses: ./.github/workflows/build.yaml
secrets: inherit
with:
environment: ${{ needs.deploy_slug.outputs.environment }}
tag: ${{ needs.deploy_slug.outputs.tag }}

deploy:
needs: [ deploy_slug, build ]
uses: ./.github/workflows/deploy.yaml
secrets: inherit
concurrency: ${{ needs.deploy_slug.outputs.environment }}
with:
environment: ${{ needs.deploy_slug.outputs.environment }}
tag: ${{ needs.deploy_slug.outputs.tag }}
3 changes: 1 addition & 2 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ jobs:
persist-credentials: false
- uses: cycjimmy/semantic-release-action@v3
with:
semantic_version: 19
working_directory: "./.github"
semantic_version: 20
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit a3241b3

Please sign in to comment.