Skip to content

chore(deps-dev): bump rollup from 2.79.1 to 2.79.2 in /rulesets (#95) #257

chore(deps-dev): bump rollup from 2.79.1 to 2.79.2 in /rulesets (#95)

chore(deps-dev): bump rollup from 2.79.1 to 2.79.2 in /rulesets (#95) #257

Workflow file for this run

name: api-standards-release
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
test:
name: validation
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: use node.js 16
uses: actions/setup-node@v3
with:
cache: npm
node-version: 16
cache-dependency-path: rulesets/package-lock.json
- run: |
npm install
working-directory: rulesets
name: install dependencies
- run: |
npm test
working-directory: rulesets
name: unit test validation
- run: |
rm sps-api-standards.spectral.yml
name: remove existing merged rulesets
- name: test merging of rulesets
uses: mikefarah/[email protected]
with:
cmd: yq eval-all '. as $item ireduce ({}; . *+ $item)' rulesets/src/*.ruleset.yml >> sps-api-standards.spectral.yml
- name: view merged rulesets
run: cat sps-api-standards.spectral.yml
release:
name: release
needs: [test]
if: github.ref == 'refs/heads/main'
runs-on: ubuntu-latest
steps:
- name: checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
persist-credentials: false
- name: zip documentation
run: zip -r sps-api-standards-documentation.zip standards
- run: |
rm sps-api-standards.spectral.yml
name: remove existing merged rulesets
- name: merge spectral rulesets
uses: mikefarah/[email protected]
with:
cmd: yq eval-all '. as $item ireduce ({}; . *+ $item)' rulesets/src/*.ruleset.yml >> sps-api-standards.spectral.yml
- name: use node.js 20
uses: actions/setup-node@v3
with:
node-version: 20
- name: install release plugins
run: npm install -g semantic-release @semantic-release/git -D
- name: semantic release
run: npx semantic-release
env:
GH_TOKEN: ${{ secrets.GH_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
- name: azure pipelines publishing
uses: Azure/pipelines@v1
with:
azure-devops-project-url: https://dev.azure.com/spscommerce/api-lifecycle
azure-pipeline-name: "sps-api-standards-cdn-publish"
azure-devops-token: ${{ secrets.AZURE_DEVOPS_TOKEN }}