Skip to content

Commit

Permalink
ci(draft): new deployment workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
Lionel Untereiner committed Oct 2, 2024
1 parent 8fbc3b9 commit 77a6509
Show file tree
Hide file tree
Showing 2 changed files with 79 additions and 67 deletions.
79 changes: 79 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,79 @@
name: Deploy

on:
pull_request: # Run workflow on PRs to the develop branch
branches:
- develop
workflow_dispatch:


jobs:
deploy:
runs-on: ubuntu-latest

steps:
- name: Checkout Code
uses: actions/[email protected]
with:
submodules: false
lfs: false

# - name: Detect API Change
# id: changed-api
# uses: tj-actions/changed-files@v43
# with:
# # Avoid using single or double quotes for multiline patterns
# files: |
# src/coreComponents/schema/**/*.{xsd,rst}

# - name: Run step if test file(s) change
# if: steps.changed-api.outputs.any_changed == 'true'
# env:
# BUMP_BEHAVIOR: "major"
# run: |
# echo "Must be a major change"

- name: Get Next Version
id: semver
uses: ietf-tools/[email protected]
with:
token: ${{ secrets.GITHUB_TOKEN }}
branch: develop
noVersionBumpBehavior: patch

- name: Create Draft Release
uses: ncipollo/[email protected]
with:
prerelease: true
draft: false
commit: ${{ github.sha }}
tag: ${{ steps.semver.outputs.nextStrict }}
name: ${{ steps.semver.outputs.nextStrict }}
body: '*pending*'
token: ${{ secrets.GITHUB_TOKEN }}

- name: Update CHANGELOG
id: changelog
uses: requarks/[email protected]
with:
token: ${{ github.token }}
fromTag: ${{ steps.semver.outputs.nextStrict }}
toTag: ${{ steps.semver.outputs.current }}
excludeTypes: ''
writeToFile: false

- name: Extract docker image tag
id: extract_docker_image_tag
run: |
echo "${{ steps.changelog.outputs.changes }}"
- name: Create Release
uses: ncipollo/[email protected]
with:
allowUpdates: true
makeLatest: true
draft: false
tag: ${{ steps.semver.outputs.nextStrict }}
name: ${{ steps.semver.outputs.nextStrict }}
body: ${{ steps.changelog.outputs.changes }}
token: ${{ secrets.GITHUB_TOKEN }}
67 changes: 0 additions & 67 deletions .github/workflows/release.yml

This file was deleted.

0 comments on commit 77a6509

Please sign in to comment.