Skip to content

feat(ref: no-ref): update ng 19 #16

feat(ref: no-ref): update ng 19

feat(ref: no-ref): update ng 19 #16

Workflow file for this run

name: Publish bun
on:
push:
branches:
- master
jobs:
build:
runs-on: ubuntu-latest
outputs:
version: ${{ steps.get_version.outputs.version }}
steps:
- uses: actions/checkout@v4
with:
submodules: true
- uses: oven-sh/setup-bun@v2
with:
bun-version: latest
- uses: actions/setup-node@v4
with:
node-version: 20
registry-url: 'https://registry.npmjs.org'
- name: Build library
run: |
bun i
bun run build:lib
- name: Setup npm token
run: |
echo "//registry.npmjs.org/:_authToken=${{ secrets.npm_token }}" > dist/ngx-loader-indicator-lib/.npmrc
- name: Publish library
run: bun run publish:lib
env:
NODE_AUTH_TOKEN: ${{secrets.npm_token}}
- name: Extract version
id: get_version
run: |
VERSION=$(node -p "require('./dist/ngx-loader-indicator-lib/package.json').version")
echo "version=$VERSION" >> $GITHUB_OUTPUT
slack_notification:
needs:
- build
runs-on: ubuntu-latest
steps:
- name: Post to a Slack channel
id: slack
uses: slackapi/[email protected]
with:
channel-id: 'deployments'
payload: |
{
"text": "GitHub Action build result: ${{ job.status == 'success' && ':white_check_mark:' || ':x:' }}",
"blocks": [
{
"type": "section",
"text": {
"type": "mrkdwn",
"text": "GitHub Action build result: ${{ job.status == 'success' && ':white_check_mark:' || ':x:' }}"
}
},
{
"type": "section",
"text": {
"type": "mrkdwn",
"text": "Project: `${{ github.event.repository.name }}`"
}
},
{
"type": "section",
"text": {
"type": "mrkdwn",
"text": "Commit/PR URL: ${{ github.event.pull_request.html_url || github.event.head_commit.url }}"
}
},
{
"type": "section",
"text": {
"type": "mrkdwn",
"text": "Version: `${{ needs.build.outputs.version || 'TBA' }}`"
}
},
{
"type": "section",
"text": {
"type": "mrkdwn",
"text": "Website URL: ${{ secrets.NPM_PACKAGE_URL || 'TBA' }}"
}
}
]
}
env:
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}