Skip to content

Commit

Permalink
Merge pull request #5730 from microsoft/shims
Browse files Browse the repository at this point in the history
Fix unsigned kiota.exe file when installed as dotnet tool.
  • Loading branch information
andrueastman authored Nov 7, 2024
2 parents 28185f0 + c52d35d commit 1bd3e43
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 1 deletion.
3 changes: 3 additions & 0 deletions .azure-pipelines/ci-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -163,6 +163,9 @@ extends:
- pwsh: $(Build.SourcesDirectory)/scripts/get-prerelease-version.ps1 -currentBranch $(Build.SourceBranch) -previewBranch ${{ parameters.previewBranch }} -excludeHeadingDash
displayName: "Set version suffix"

- pwsh: $(Build.SourcesDirectory)/scripts/enable-shims-for-packaging.ps1
displayName: "Add PackAsToolShimRuntimeIdentifiers attributes for tool packaging"

- pwsh: $(Build.SourcesDirectory)/scripts/update-version-suffix-for-source-generator.ps1 -versionSuffix "$(versionSuffix)"
displayName: "Set version suffix in csproj for generators"

Expand Down
3 changes: 2 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Added

### Changed

- Fixed python generation client serailization failure str being quoted as "str"
- Fixed Issue with primitive values being stringified in python python. [#5417](https://github.com/microsoft/kiota/issues/5417)

- Fixed an issue where multipart request content would be ignored if other unstructured content was present in the description. [#5638](https://github.com/microsoft/kiota/issues/5638)
- Fixed an issue where when generating Go code the deserializer for unions was using `CodeClass` as a filter and not `CodeInterface`. [#4844](https://github.com/microsoft/kiota/issues/4844)
- Fixes mapping of `int16` format to the `integer` type rather than `double` when the type is `integer` or `number` [#5611](https://github.com/microsoft/kiota/issues/5611)
Expand All @@ -23,6 +23,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Fixed a bug where the type name for inherited inline models would be incorrect. [#5610](https://github.com/microsoft/kiota/issues/5610)
- Fixes typing inconsistencies in generated code and libraries in Python [kiota-python#333](https://github.com/microsoft/kiota-python/issues/333)
- Fixes generation of superfluous fields for Models with discriminator due to refiners adding the same properties to the same model [#4178](https://github.com/microsoft/kiota/issues/4178).
- Fixes unsigned shim binary when installed as dotnet tool [#5650](https://github.com/microsoft/kiota/issues/5650).

## [1.19.1] - 2024-10-11

Expand Down
13 changes: 13 additions & 0 deletions scripts/enable-shims-for-packaging.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# This script enables the shims for packaging the project as a tool
$csprojPath = Join-Path $PSScriptRoot "../src/kiota/kiota.csproj"

$xml = [Xml] (Get-Content $csprojPath)

$shimIdentifiers = $xml.CreateElement("PackAsToolShimRuntimeIdentifiers")
$shimIdentifiers.InnerText = "win-x64;win-x86;osx-x64"

$rootPropertyGroup = $xml.Project.PropertyGroup[0]
$rootPropertyGroup.AppendChild($shimIdentifiers)

#save xml to csproj
$xml.Save($csprojPath)

0 comments on commit 1bd3e43

Please sign in to comment.