Skip to content

Release ACA libs from branch ACS-9068-aca-pipeline-changes-enabling-packagage-release #89

Release ACA libs from branch ACS-9068-aca-pipeline-changes-enabling-packagage-release

Release ACA libs from branch ACS-9068-aca-pipeline-changes-enabling-packagage-release #89

Workflow file for this run

name: Release ACA libs from branch
run-name: Release ACA libs from branch ${{ github.ref_name }}
on:
workflow_dispatch:
inputs:
dry-run-flag:
description: 'enable dry-run'
required: false
type: boolean
default: true
env:
BASE_URL: ${{ secrets.PIPELINE_ENV_URL }}
jobs:
lint:
name: 'lint'
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: node
uses: actions/setup-node@v4
with:
node-version-file: '.nvmrc'
cache: 'npm'
- run: npm ci
- run: npm run affected:lint -- --base=origin/develop
- run: npm run stylelint
unit-tests:
needs: [lint]
name: "Unit tests: ${{ matrix.unit-tests.name }}"
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
unit-tests:
- name: "aca-content"
- name: "aca-shared"
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: node
uses: actions/setup-node@v4
with:
node-version-file: '.nvmrc'
cache: 'npm'
- uses: ./.github/actions/before-install
- run: npm ci
- run: npm run affected:test -- --browsers=ChromeHeadless --watch=false $TEST_OPTS --base=origin/develop
publish-libs:
needs: [lint, unit-tests]
name: "Publish libs to NPM and GitHub registry"
runs-on: ubuntu-latest
permissions:
packages: write
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 2
- name: Setup node
uses: actions/setup-node@v4
with:
node-version-file: '.nvmrc'
cache: 'npm'
- uses: Alfresco/alfresco-build-tools/.github/actions/[email protected]
- name: publish
uses: ./.github/actions/publish-libs
with:
branch_name: ${{ env.BRANCH_NAME }}
github_token: ${{ secrets.BOT_GITHUB_TOKEN }}
npm_registry_token: ${{ secrets.NPM_REGISTRY_TOKEN }}
npm_tag: 'branch'
dry-run: ${{ inputs.dry-run-flag }}