Skip to content

fix: report committers through day is inclusive to end of day #14

fix: report committers through day is inclusive to end of day

fix: report committers through day is inclusive to end of day #14

Workflow file for this run

name: Release
on:
push:
tags:
- 'v[0-9]+.[0-9]+.[0-9]+**'
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: ./.github/workflows/composite/build
build-seas:
needs: build
uses: ./.github/workflows/build-seas.yml
verify:
needs: build-seas
uses: ./.github/workflows/runtime-tests.yml
release:
runs-on: ubuntu-latest
needs: verify
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
steps:
- uses: actions/checkout@v4
- name: restore the dist directory from cache
uses: actions/cache/restore@v4
with:
path: ./dist/apps/cli
key: hdcli-dist-${{ github.run_id }}
- name: release-version
uses: actions/github-script@v7
id: release-version
env:
GIT_TAG: ${{ github.ref_name }}
with:
script: |
const releaseVersion = process.env.GIT_TAG.slice(1);
console.log(`Release version: ${releaseVersion}`);
return releaseVersion;
result-encoding: string
- name: update package.json and publish
working-directory: dist/apps/cli
env:
NODE_AUTH_TOKEN: ${{ secrets.HD_CLI_NPM_TOKEN }}
run: |
npm version "${{ steps.release-version.outputs.result }}" --no-git-tag-version
npm publish
- name: restore the linux zip from cache
uses: actions/cache/save@v4
with:
key: hdcli-sea-linux-latest-zip-${{ github.run_id }}
path: ./dist/apps/cli/hdcli-linux.zip
enableCrossOsArchive: true
- name: restore the macos zip from cache
uses: actions/cache/save@v4
with:
key: hdcli-sea-macos-zip-${{ github.run_id }}
path: ./dist/apps/cli/hdcli-macos.zip
enableCrossOsArchive: true
- name: restore the windows zip from cache
uses: actions/cache/save@v4
with:
key: hdcli-sea-windows-zip-${{ github.run_id }}
path: ./dist/apps/cli/hdcli.exe-windows.zip
enableCrossOsArchive: true
- name: create release
id: create-release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.ref }}
release_name: Release ${{ github.ref_name }}
draft: false
prerelease: false
- name: upload linux zip asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create-release.outputs.upload_url }}
asset_path: ./dist/apps/cli/hdcli-linux.zip
asset_name: hdcli-linux.zip
asset_content_type: application/zip
- name: upload macos zip asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create-release.outputs.upload_url }}
asset_path: ./dist/apps/cli/hdcli-macos.zip
asset_name: hdcli-macos.zip
asset_content_type: application/zip
- name: upload windows zip asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create-release.outputs.upload_url }}
asset_path: ./dist/apps/cli/hdcli-windows.zip
asset_name: hdcli-windows.zip
asset_content_type: application/zip