Skip to content

Commit

Permalink
Update kiota (#175)
Browse files Browse the repository at this point in the history
* Update microsoft.openapi.kiota

* Drop custom kiota build

* Use EnvironmentVariables
  • Loading branch information
trejjam authored Aug 30, 2024
1 parent 05e8c46 commit d8ccb67
Show file tree
Hide file tree
Showing 6 changed files with 4 additions and 20 deletions.
4 changes: 2 additions & 2 deletions .config/dotnet-tools.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@
"isRoot": true,
"tools": {
"microsoft.openapi.kiota": {
"version": "1.17.0",
"version": "1.18.0-preview.202408290001",
"commands": [
"kiota"
],
"rollForward": false
}
}
}
}
4 changes: 0 additions & 4 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,12 +22,8 @@ jobs:
- uses: actions/checkout@v4
- name: Tool restore
run: dotnet tool restore
- uses: ./.github/actions/build-kiota
id: kiota
- name: Restore
run: dotnet restore --nologo
env:
KIOTA_BIN: ${{ steps.kiota.outputs.command }}
- name: Build
run: dotnet build --no-restore --nologo --configuration Release
- name: Test
Expand Down
4 changes: 0 additions & 4 deletions .github/workflows/nightly-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,8 @@ jobs:
run: git fetch --prune --unshallow
- name: Tool restore
run: dotnet tool restore
- uses: ./.github/actions/build-kiota
id: kiota
- name: Restore
run: dotnet restore --nologo
env:
KIOTA_BIN: ${{ steps.kiota.outputs.command }}
- uses: ./.github/actions/version
id: version
- name: Build with .Net
Expand Down
4 changes: 0 additions & 4 deletions .github/workflows/pr-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,12 +22,8 @@ jobs:
- uses: actions/checkout@v4
- name: Tool restore
run: dotnet tool restore
- uses: ./.github/actions/build-kiota
id: kiota
- name: Restore
run: dotnet restore --nologo
env:
KIOTA_BIN: ${{ steps.kiota.outputs.command }}
- name: Build
run: dotnet build --no-restore --nologo --configuration Release
- name: Test
Expand Down
4 changes: 0 additions & 4 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,8 @@ jobs:
echo "NuGetPreReleaseTagV2 (not used): ${{ steps.gitversion.outputs.CommitsSinceVersionSourcePadded }}"
- name: Tool restore
run: dotnet tool restore
- uses: ./.github/actions/build-kiota
id: kiota
- name: Restore
run: dotnet restore --nologo
env:
KIOTA_BIN: ${{ steps.kiota.outputs.command }}
- uses: ./.github/actions/version
id: version
- name: Build with .Net
Expand Down
4 changes: 2 additions & 2 deletions src/Apple.AppStoreConnect/Apple.AppStoreConnect.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
<KiotaCommand>$(KIOTA_BIN)</KiotaCommand>
<KiotaCommand Condition=" '$(KiotaCommand)' == '' ">dotnet kiota</KiotaCommand>

<KiotaExec>KIOTA_TUTORIAL_ENABLED=false $(KiotaCommand) generate</KiotaExec>
<KiotaExec>$(KiotaCommand) generate</KiotaExec>
<KiotaExec>$(KiotaExec) --openapi $(MSBuildProjectDirectory)/$(AppStoreConnectOpenApiSpecificationExtracted)/$(AppStoreConnectOpenApiSpecificationJson)</KiotaExec>
<KiotaExec>$(KiotaExec) --language csharp</KiotaExec>
<KiotaExec>$(KiotaExec) --exclude-backward-compatible</KiotaExec>
Expand Down Expand Up @@ -91,7 +91,7 @@
<Target Name="GenerateClient" BeforeTargets="Restore;_GenerateRestoreProjectSpec" AfterTargets="PreprocessOpenApiSpecification" Condition=" $(GenerateClient) == 'true' And !Exists('$(MSBuildProjectDirectory)/$(GeneratedCodeTarget)')">
<Message Importance="High" Text="Generating client to the $(MSBuildProjectDirectory)/$(GeneratedCodeTarget) using $(KiotaCommand)" />

<Exec WorkingDirectory="$(ProjectDir)" Command="$(KiotaExec)" />
<Exec WorkingDirectory="$(ProjectDir)" EnvironmentVariables="KIOTA_TUTORIAL_ENABLED=false" Command="$(KiotaExec)" />
</Target>

</Project>

0 comments on commit d8ccb67

Please sign in to comment.