AleksanderSklorz e9bc42df10
[ACS-4534] nx workspace support for aca (#3143)
* ACS-4534 Added nx workspace support

* ACS-4534 Updated package-lock.json file

* ACS-4534 Configured cache directory and affected command

* ACS-4534 Updated README

* ACS-4534 Updated more README files

* ACS-4534 Fixed lint

* ACS-4534 Address comment for readme

* ACS-4534 Removed redundant build-libs script

* ACS-4534 Fixed start script

* ACS-4534 Updated some left documentation

* ACS-4534 Added more helper scripts, addressed PR comments

* ACS-4534 Updated package-lock.json after rebasing

* ACS-4534 Fix stylelint issue
2023-04-25 15:34:34 +02:00

72 lines
1.8 KiB
YAML

name: "Publish ACA libs to NPM and GH registry"
description: "Publish ACA libs to NPM and GH registry"
inputs:
branch_name:
description: 'Name of the branch the workflow runs on'
required: true
type: string
github_token:
description: 'Github token'
required: true
type: string
npm_registry_address:
description: 'NPM registry address'
required: true
type: string
npm_registry_token:
description: 'NPM registry token'
required: true
type: string
npm_tag:
description: 'NPM tag'
required: true
type: string
dry-run:
description: dry run flag
required: true
type: boolean
runs:
using: "composite"
steps:
- uses: ./.github/actions/update-library-versions
name: Update Library Versions
with:
branch_name: ${{ env.BRANCH_NAME }}
dry-run: ${{ inputs.dry-run }}
- name: Build Libraries
shell: bash
run: npm ci && npm run build
- uses: actions/setup-node@v3
name: setup GH registry
with:
node-version-file: '.nvmrc'
registry-url: 'https://npm.pkg.github.com'
scope: '@alfresco'
- name: Publish to GH registry
shell: bash
run: ${{ github.action_path }}/npm-publish.sh "$TAG" "$DRY_RUN"
env:
NODE_AUTH_TOKEN: ${{ inputs.github_token }}
TAG: ${{ inputs.npm_tag }}
DRY_RUN: ${{ inputs.dry-run }}
- uses: actions/setup-node@v3
name: setup NPM registry
with:
node-version-file: '.nvmrc'
registry-url: 'https://${{ inputs.npm_registry_address }}'
scope: '@alfresco'
- name: Publish to NPM registry
shell: bash
run: ${{ github.action_path }}/npm-publish.sh "$TAG" "$DRY_RUN"
env:
NODE_AUTH_TOKEN: ${{ inputs.npm_registry_token }}
TAG: ${{ inputs.npm_tag }}
DRY_RUN: ${{ inputs.dry-run }}