This repository has been archived by the owner on Jan 28, 2024. It is now read-only.
ci(deps): bump github/codeql-action from 2 to 3 (#509) #157
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
name: CD | |
# **What it does**: Automatically generates releases and release notes. | |
# **Why we have it**: Allows development to focus on higher value work. | |
on: | |
push: | |
branches: | |
- main | |
# Allows this workflow to be run manually from the Actions tab | |
workflow_dispatch: | |
permissions: | |
contents: write | |
pull-requests: write | |
jobs: | |
release: | |
name: Create/Update Release Pull Request | |
runs-on: ubuntu-latest | |
outputs: | |
release_created: ${{ steps.release.outputs.release_created }} | |
tag_name: ${{ steps.release.outputs.tag_name }} | |
upload_url: ${{ steps.release.outputs.upload_url }} | |
steps: | |
- name: Release Please | |
id: release | |
uses: google-github-actions/release-please-action@v3 | |
with: | |
changelog-types: '[ { "type": "feat", "section": "Features", "hidden": false }, { "type": "fix", "section": "Bug fixes", "hidden": false }, { "type": "build", "section": "Dependencies", "hidden": false }, { "type": "chore", "section": "Miscellaneous", "hidden": false }, { "type": "ci", "section": "Continuous integration", "hidden": false }, { "type": "perf", "section": "Improvements", "hidden": false }, { "type": "refactor", "section": "Improvements", "hidden": false }, { "type": "style", "section": "Miscellaneous", "hidden": false }, { "type": "docs", "section": "Documentation", "hidden": false }]' | |
release-type: node | |
assets: | |
name: Create and Upload Release Asset | |
needs: release | |
if: needs.release.outputs.release_created == 'true' | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check out repo | |
uses: actions/checkout@v4 | |
with: | |
persist-credentials: false | |
- name: Create release asset | |
run: > | |
mkdir dist/sql && cp src/sql/**-Lookup-Table.sql dist/sql && | |
zip -r ${{ github.event.repository.name }}-${{ needs.release.outputs.tag_name }}.zip | |
LICENSE README.md | |
dist | |
- name: Upload release asset | |
uses: actions/upload-release-asset@v1 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
upload_url: ${{ needs.release.outputs.upload_url }} | |
asset_path: ./${{ github.event.repository.name }}-${{ needs.release.outputs.tag_name }}.zip | |
asset_name: ${{ github.event.repository.name }}-${{ needs.release.outputs.tag_name }}.zip | |
asset_content_type: application/zip |