Skip to content

chore(deps): update github/codeql-action digest to a09933a (#350) #367

chore(deps): update github/codeql-action digest to a09933a (#350)

chore(deps): update github/codeql-action digest to a09933a (#350) #367

Workflow file for this run

name: release
on:
push:
branches:
- main
jobs:
release-external:
runs-on: ubuntu-latest
env:
GITHUB_TOKEN: placeholder
outputs:
released_version: ${{ steps.release.outputs.released_version }}
steps:
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3
- uses: actions/setup-node@bea5baf987ba7aa777a8a0b4ace377a21c45c381 # v3
with:
node-version: 18
- run: npm ci
- run: npm run build
- run: npm run check
- uses: crazy-max/ghaction-import-gpg@72b6676b71ab476b77e676928516f6982eef7a41 # v5
with:
gpg_private_key: ${{secrets.STEDI_ENGINEERING_PUBLIC_REPO_GPG_PRIVATE_KEY}}
passphrase: ${{secrets.STEDI_ENGINEERING_PUBLIC_REPO_GPG_PASSPHRASE}}
git_user_signingkey: true
git_commit_gpgsign: true
id: import_gpg
- run: 'echo "email: ${{ steps.import_gpg.outputs.email }}"'
- run: npm run release
id: release
env:
GIT_AUTHOR_NAME: ${{steps.import_gpg.outputs.name}}
GIT_COMMITTER_NAME: ${{steps.import_gpg.outputs.name}}
GIT_AUTHOR_EMAIL: ${{steps.import_gpg.outputs.email}}
GIT_COMMITTER_EMAIL: ${{steps.import_gpg.outputs.email}}
NPM_TOKEN: ${{secrets.NPM_TOKEN}}
- run: npm cache clear --force
release-internal:
needs: [release-external]
if: needs.release-external.outputs.released_version != ''
runs-on: ubuntu-latest
env:
GITHUB_TOKEN: placeholder
steps:
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3
- uses: actions/setup-node@bea5baf987ba7aa777a8a0b4ace377a21c45c381 # v3
with:
node-version: 18
- run: 'echo "released_version: ${{needs.release-external.outputs.released_version}}"'
- run: npm ci
- run: npm run build
- run: npm run check
- uses: crazy-max/ghaction-import-gpg@72b6676b71ab476b77e676928516f6982eef7a41 # v5
with:
gpg_private_key: ${{secrets.STEDI_ENGINEERING_PUBLIC_REPO_GPG_PRIVATE_KEY}}
passphrase: ${{secrets.STEDI_ENGINEERING_PUBLIC_REPO_GPG_PASSPHRASE}}
git_user_signingkey: true
git_commit_gpgsign: true
id: import_gpg
- run: npm version ${{needs.release-external.outputs.released_version}} --allow-same-version
env:
GIT_AUTHOR_NAME: ${{steps.import_gpg.outputs.name}}
GIT_COMMITTER_NAME: ${{steps.import_gpg.outputs.name}}
GIT_AUTHOR_EMAIL: ${{steps.import_gpg.outputs.email}}
GIT_COMMITTER_EMAIL: ${{steps.import_gpg.outputs.email}}
NPM_TOKEN: ${{secrets.NPM_TOKEN}}
- run: sed -i 's/registry.npmjs.org/npm.pkg.github.com\/Stedi/' package.json
- run: sed -i '/"access":\ "public"/d' package.json
- run: npm publish
env:
GITHUB_TOKEN: ${{ secrets.PRETTIER_PLUGIN_JSONATA_GITHUB_TOKEN }}