Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Set file versions in release workflow #120

Merged
merged 45 commits into from
Nov 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
45 commits
Select commit Hold shift + click to select a range
d7d7120
Set file versions in release workflow
lemccomb Nov 14, 2024
3dd2c35
Update changelog for release
actions-user Nov 14, 2024
6e4ea80
make the function testable from PR
lemccomb Nov 14, 2024
7521d9e
Merge branch 'user/lemccomb/versioning' of https://github.com/microso…
lemccomb Nov 14, 2024
48e9346
don't wait for create_release
lemccomb Nov 14, 2024
184435f
fix path to proj files
lemccomb Nov 14, 2024
62a1fb0
move the exit point so I can see outputs
lemccomb Nov 14, 2024
98a0750
allow publish
lemccomb Nov 14, 2024
0245761
Update changelog for release
actions-user Nov 14, 2024
d8c9289
verify file write in code
lemccomb Nov 14, 2024
8bab4f8
Merge branch 'user/lemccomb/versioning' of https://github.com/microso…
lemccomb Nov 14, 2024
999b07b
clarity of result
lemccomb Nov 14, 2024
092c4c0
production ready
lemccomb Nov 14, 2024
961872b
try using -p: to set version
lemccomb Nov 15, 2024
ed2cfc8
$VERSION
lemccomb Nov 15, 2024
45541cd
simplify
lemccomb Nov 15, 2024
9952d8a
no vars
lemccomb Nov 15, 2024
94c9f47
path
lemccomb Nov 15, 2024
400f20f
check publish
lemccomb Nov 15, 2024
352379e
the .
lemccomb Nov 15, 2024
c9b9620
set working dir
lemccomb Nov 15, 2024
3ec04bf
get-item
lemccomb Nov 15, 2024
d894411
paths
lemccomb Nov 15, 2024
b58bb18
dll
lemccomb Nov 15, 2024
f31c44f
kill parens
lemccomb Nov 15, 2024
d034dec
tweak
lemccomb Nov 16, 2024
80051a7
$
lemccomb Nov 16, 2024
cae5cca
test publish early
lemccomb Nov 19, 2024
ff80565
try publish early and dotnet exec to read version
lemccomb Nov 19, 2024
c812463
remove additional probing path
lemccomb Nov 19, 2024
e5f0be3
try another PS syntax
lemccomb Nov 19, 2024
c362184
fix ps version
lemccomb Nov 19, 2024
76235eb
file path
lemccomb Nov 19, 2024
b9e2317
validate call syntax
lemccomb Nov 19, 2024
dc24293
get rid of exit
lemccomb Nov 19, 2024
4c8e02a
alternate syntax
lemccomb Nov 19, 2024
4110170
cleanup
lemccomb Nov 19, 2024
c442394
remove hard-coded file version
lemccomb Nov 19, 2024
861449b
remove hard-coded file version
lemccomb Nov 19, 2024
eafa819
remove hard-coded file version
lemccomb Nov 19, 2024
a733da3
remove hard-coded file version
lemccomb Nov 19, 2024
d7b1aa5
remove hard-coded file version
lemccomb Nov 19, 2024
25eaf94
remove hard-coded file version
lemccomb Nov 19, 2024
3046c5d
remove hard-coded file version
lemccomb Nov 19, 2024
88dc9e1
remove exit
lemccomb Nov 20, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 21 additions & 5 deletions .github/workflows/dotnet.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,15 +49,16 @@ jobs:
# Use the Dotnet Test command to load dependencies, build, and test the code.
# We have to run the test projects individually so CoseSignTool.Tests can run under arm64 on the Mac runner.
- name: Build and Test debug
id: build-test
run: |
dotnet build --configuration Debug CoseSignTool.sln
dotnet test --no-restore CoseSign1.Tests/CoseSign1.Tests.csproj
dotnet test --no-restore CoseSign1.Certificates.Tests/CoseSign1.Certificates.Tests.csproj
dotnet test --no-restore CoseSign1.Headers.Tests/CoseSign1.Headers.Tests.csproj
dotnet test --no-restore CoseIndirectSignature.Tests/CoseIndirectSignature.Tests.csproj
dotnet test --no-restore CoseHandler.Tests/CoseHandler.Tests.csproj
dotnet test --no-restore CoseSignTool.Tests/CoseSignTool.Tests.csproj --verbosity detailed
dotnet test --no-restore CoseSignTool.Tests/CoseSignTool.Tests.csproj

# List the contents of the working directory to make sure all the artifacts are there.
- name: List working directory
run: ${{ matrix.dir_command }}
Expand All @@ -80,7 +81,7 @@ jobs:
- name: Checkout code
if: ${{ github.event_name == 'pull_request' }}
uses: actions/checkout@v2

# Sync the changelog version.
- name: Fetch and checkout
if: ${{ github.event_name == 'pull_request' }}
Expand Down Expand Up @@ -273,9 +274,24 @@ jobs:
# Build and publish the binaries to ./published.
- name: Publish outputs
run: |
dotnet publish --configuration Debug --self-contained true --output published/debug CoseSignTool/CoseSignTool.csproj
dotnet publish --configuration Release --self-contained true --output published/release CoseSignTool/CoseSignTool.csproj
VERSION=${{ needs.create_release.outputs.tag_name }}
dotnet publish --configuration Debug --self-contained true --output published/debug --property:FileVersion=$VERSION CoseSignTool/CoseSignTool.csproj
dotnet publish --configuration Release --self-contained true --output published/release --property:FileVersion=$VERSION CoseSignTool/CoseSignTool.csproj
# Self-contained is needed. Must use .csproj instead of .sln.

# List the contents of the published directory to make sure all the artifacts are there.
- name: List published directory
run: ${{ matrix.dir_command }}
working-directory: ./published

# Verify that the file versions on the DLLs match the release version
- name: Check File Version
run: |
$file = Get-Item "CoseSignTool.dll"
$version = $file.VersionInfo.FileVersion
Write-Output "File Version is $version"
shell: pwsh
working-directory: ./published/debug

# Copy the docs, license, and markdown files to the release folders.
- name: Copy docs to release folders
Expand Down
104 changes: 66 additions & 38 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,33 @@
# Changelog

## [v0.0.0-Test1](https://github.com/microsoft/CoseSignTool/tree/v0.0.0-Test1) (2024-10-30)

[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.2.8-pre7...v0.0.0-Test1)

## [v1.2.8-pre7](https://github.com/microsoft/CoseSignTool/tree/v1.2.8-pre7) (2024-10-30)

[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.3.0...v1.2.8-pre7)

**Closed issues:**

- Revocation and Root Trust [\#119](https://github.com/microsoft/CoseSignTool/issues/119)

**Merged pull requests:**

- Adds CLI install instructions [\#116](https://github.com/microsoft/CoseSignTool/pull/116) ([ivarprudnikov](https://github.com/ivarprudnikov))

## [v1.3.0](https://github.com/microsoft/CoseSignTool/tree/v1.3.0) (2024-10-30)

[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.2.8-pre6...v1.3.0)

## [v1.2.8-pre6](https://github.com/microsoft/CoseSignTool/tree/v1.2.8-pre6) (2024-10-30)

[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.2.8-pre5...v1.2.8-pre6)

**Merged pull requests:**

- .NET 8 Revocation and Root Trust Bugfix [\#118](https://github.com/microsoft/CoseSignTool/pull/118) ([elantiguamsft](https://github.com/elantiguamsft))

## [v1.2.8-pre5](https://github.com/microsoft/CoseSignTool/tree/v1.2.8-pre5) (2024-10-21)

[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.2.8-pre4...v1.2.8-pre5)
Expand All @@ -18,19 +46,19 @@

## [v1.2.8-pre3](https://github.com/microsoft/CoseSignTool/tree/v1.2.8-pre3) (2024-10-15)

[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.2.8-pre2...v1.2.8-pre3)
[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.2.8-pre1...v1.2.8-pre3)

**Merged pull requests:**

- Increase timeout for checking for empty streams [\#113](https://github.com/microsoft/CoseSignTool/pull/113) ([lemccomb](https://github.com/lemccomb))

## [v1.2.8-pre2](https://github.com/microsoft/CoseSignTool/tree/v1.2.8-pre2) (2024-09-25)
## [v1.2.8-pre1](https://github.com/microsoft/CoseSignTool/tree/v1.2.8-pre1) (2024-09-25)

[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.2.8-pre1...v1.2.8-pre2)
[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.2.8-pre2...v1.2.8-pre1)

## [v1.2.8-pre1](https://github.com/microsoft/CoseSignTool/tree/v1.2.8-pre1) (2024-09-25)
## [v1.2.8-pre2](https://github.com/microsoft/CoseSignTool/tree/v1.2.8-pre2) (2024-09-25)

[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.2.8...v1.2.8-pre1)
[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.2.8...v1.2.8-pre2)

**Merged pull requests:**

Expand Down Expand Up @@ -196,47 +224,47 @@

## [v1.2.1-pre1](https://github.com/microsoft/CoseSignTool/tree/v1.2.1-pre1) (2024-03-12)

[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.2.1...v1.2.1-pre1)
[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.2.0-pre1...v1.2.1-pre1)

**Merged pull requests:**

- Revert "Add .exe to CoseSignTool NuGet" [\#83](https://github.com/microsoft/CoseSignTool/pull/83) ([elantiguamsft](https://github.com/elantiguamsft))

## [v1.2.1](https://github.com/microsoft/CoseSignTool/tree/v1.2.1) (2024-03-07)
## [v1.2.0-pre1](https://github.com/microsoft/CoseSignTool/tree/v1.2.0-pre1) (2024-03-07)

[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.2.0-pre1...v1.2.1)
[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.2.1...v1.2.0-pre1)

## [v1.2.0-pre1](https://github.com/microsoft/CoseSignTool/tree/v1.2.0-pre1) (2024-03-07)
## [v1.2.1](https://github.com/microsoft/CoseSignTool/tree/v1.2.1) (2024-03-07)

[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.2.exeTest...v1.2.0-pre1)
[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.2.exeTest...v1.2.1)

**Merged pull requests:**

- Add .exe to CoseSignTool NuGet [\#81](https://github.com/microsoft/CoseSignTool/pull/81) ([elantiguamsft](https://github.com/elantiguamsft))

## [v1.2.exeTest](https://github.com/microsoft/CoseSignTool/tree/v1.2.exeTest) (2024-03-06)

[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.2.0...v1.2.exeTest)
[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.1.8-pre1...v1.2.exeTest)

## [v1.2.0](https://github.com/microsoft/CoseSignTool/tree/v1.2.0) (2024-03-04)
## [v1.1.8-pre1](https://github.com/microsoft/CoseSignTool/tree/v1.1.8-pre1) (2024-03-04)

[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.1.8-pre1...v1.2.0)
[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.2.0...v1.1.8-pre1)

## [v1.1.8-pre1](https://github.com/microsoft/CoseSignTool/tree/v1.1.8-pre1) (2024-03-04)
## [v1.2.0](https://github.com/microsoft/CoseSignTool/tree/v1.2.0) (2024-03-04)

[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.1.7-pre3...v1.1.8-pre1)
[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.1.8...v1.2.0)

**Merged pull requests:**

- Update Nuspec for CoseIndirectSignature [\#80](https://github.com/microsoft/CoseSignTool/pull/80) ([elantiguamsft](https://github.com/elantiguamsft))

## [v1.1.7-pre3](https://github.com/microsoft/CoseSignTool/tree/v1.1.7-pre3) (2024-03-02)
## [v1.1.8](https://github.com/microsoft/CoseSignTool/tree/v1.1.8) (2024-03-02)

[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.1.8...v1.1.7-pre3)
[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.1.7-pre3...v1.1.8)

## [v1.1.8](https://github.com/microsoft/CoseSignTool/tree/v1.1.8) (2024-03-02)
## [v1.1.7-pre3](https://github.com/microsoft/CoseSignTool/tree/v1.1.7-pre3) (2024-03-02)

[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.1.7-pre2...v1.1.8)
[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.1.7-pre2...v1.1.7-pre3)

**Merged pull requests:**

Expand Down Expand Up @@ -308,39 +336,39 @@

## [v1.1.3](https://github.com/microsoft/CoseSignTool/tree/v1.1.3) (2024-01-24)

[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.1.2...v1.1.3)
[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.1.1-pre2...v1.1.3)

**Merged pull requests:**

- Updating snk for internal package compatibility [\#72](https://github.com/microsoft/CoseSignTool/pull/72) ([elantiguamsft](https://github.com/elantiguamsft))

## [v1.1.2](https://github.com/microsoft/CoseSignTool/tree/v1.1.2) (2024-01-18)
## [v1.1.1-pre2](https://github.com/microsoft/CoseSignTool/tree/v1.1.1-pre2) (2024-01-18)

[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.1.1-pre2...v1.1.2)
[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.1.2...v1.1.1-pre2)

## [v1.1.1-pre2](https://github.com/microsoft/CoseSignTool/tree/v1.1.1-pre2) (2024-01-18)
## [v1.1.2](https://github.com/microsoft/CoseSignTool/tree/v1.1.2) (2024-01-18)

[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.1.1-pre1...v1.1.1-pre2)
[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.1.1-pre1...v1.1.2)

**Merged pull requests:**

- Add logging for failure paths as well as some various improvements to the code base. [\#71](https://github.com/microsoft/CoseSignTool/pull/71) ([JeromySt](https://github.com/JeromySt))

## [v1.1.1-pre1](https://github.com/microsoft/CoseSignTool/tree/v1.1.1-pre1) (2024-01-17)

[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.1.0-pre7...v1.1.1-pre1)
[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.1.1...v1.1.1-pre1)

**Merged pull requests:**

- Move CreateChangelog to after build in PR build [\#70](https://github.com/microsoft/CoseSignTool/pull/70) ([lemccomb](https://github.com/lemccomb))

## [v1.1.0-pre7](https://github.com/microsoft/CoseSignTool/tree/v1.1.0-pre7) (2024-01-12)
## [v1.1.1](https://github.com/microsoft/CoseSignTool/tree/v1.1.1) (2024-01-12)

[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.1.1...v1.1.0-pre7)
[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.1.0-pre7...v1.1.1)

## [v1.1.1](https://github.com/microsoft/CoseSignTool/tree/v1.1.1) (2024-01-12)
## [v1.1.0-pre7](https://github.com/microsoft/CoseSignTool/tree/v1.1.0-pre7) (2024-01-12)

[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.1.0-pre6...v1.1.1)
[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.1.0-pre6...v1.1.0-pre7)

**Closed issues:**

Expand Down Expand Up @@ -397,7 +425,7 @@

## [v1.1.0-pre1](https://github.com/microsoft/CoseSignTool/tree/v1.1.0-pre1) (2023-11-03)

[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v0.3.1-pre.10...v1.1.0-pre1)
[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.1.0...v1.1.0-pre1)

**Merged pull requests:**

Expand All @@ -407,13 +435,13 @@
- DetachedSignatureFactory accepts pre-hashed content as payload [\#53](https://github.com/microsoft/CoseSignTool/pull/53) ([elantiguamsft](https://github.com/elantiguamsft))
- Add password support for certificate files [\#52](https://github.com/microsoft/CoseSignTool/pull/52) ([lemccomb](https://github.com/lemccomb))

## [v0.3.1-pre.10](https://github.com/microsoft/CoseSignTool/tree/v0.3.1-pre.10) (2023-10-10)
## [v1.1.0](https://github.com/microsoft/CoseSignTool/tree/v1.1.0) (2023-10-10)

[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v1.1.0...v0.3.1-pre.10)
[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v0.3.1-pre.10...v1.1.0)

## [v1.1.0](https://github.com/microsoft/CoseSignTool/tree/v1.1.0) (2023-10-10)
## [v0.3.1-pre.10](https://github.com/microsoft/CoseSignTool/tree/v0.3.1-pre.10) (2023-10-10)

[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v0.3.1-pre.9...v1.1.0)
[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v0.3.2...v0.3.1-pre.10)

**Merged pull requests:**

Expand All @@ -423,13 +451,13 @@
- Port changes from ADO repo to GitHub repo [\#46](https://github.com/microsoft/CoseSignTool/pull/46) ([lemccomb](https://github.com/lemccomb))
- Re-enable CodeQL [\#45](https://github.com/microsoft/CoseSignTool/pull/45) ([lemccomb](https://github.com/lemccomb))

## [v0.3.1-pre.9](https://github.com/microsoft/CoseSignTool/tree/v0.3.1-pre.9) (2023-09-28)
## [v0.3.2](https://github.com/microsoft/CoseSignTool/tree/v0.3.2) (2023-09-28)

[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v0.3.2...v0.3.1-pre.9)
[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v0.3.1-pre.9...v0.3.2)

## [v0.3.2](https://github.com/microsoft/CoseSignTool/tree/v0.3.2) (2023-09-28)
## [v0.3.1-pre.9](https://github.com/microsoft/CoseSignTool/tree/v0.3.1-pre.9) (2023-09-28)

[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v0.3.1-pre.8...v0.3.2)
[Full Changelog](https://github.com/microsoft/CoseSignTool/compare/v0.3.1-pre.8...v0.3.1-pre.9)

**Merged pull requests:**

Expand Down
Loading