Files
actions/.github/workflows/release.yml
dependabot[bot] 31e312b4a0 (build deps): Bump actions/checkout from 3 to 4
Bumps [actions/checkout](https://github.com/actions/checkout) from 3 to 4.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v3...v4)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-09-05 05:09:11 +00:00

48 lines
1.3 KiB
YAML

name: release
on:
release:
types: [published]
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest]
steps:
- uses: actions/checkout@v4
- name: Fetch all history for all tags and branches
run: |
git fetch --prune --unshallow
- run: |
npm install
npm run build:github
npm run build:azure
# npm run compress:github
# npm run compress:azure
name: Build code
- name: Install GitVersion
uses: ./gitversion/setup
with:
versionSpec: '5.x'
- name: Use GitVersion
id: gitversion # step id used as reference for output values
uses: ./gitversion/execute
- run: |
$date = Get-Date -format "yyMMddHH"
$version = "${{steps.gitversion.outputs.majorMinorPatch}}.$date"
$major = "${{steps.gitversion.outputs.major}}"
$minor = "${{steps.gitversion.outputs.minor}}"
$patch = "${{steps.gitversion.outputs.patch}}"
. .\dist\azure\update-version.ps1
update-manifest .\dist\azure\vss-extension.json -Version $version
dir -r .\dist\**\task.json | % { update-task $_ -Major $major -Minor $minor -Patch $patch }
npm run publish:azure -- --token ${{ secrets.TFX_TOKEN }}
shell: pwsh
name: Publish Azure extension