Skip to content

Commit

Permalink
feat: Update to net9
Browse files Browse the repository at this point in the history
  • Loading branch information
HavenDV committed Nov 14, 2024
1 parent ffebe2a commit 1bb5ed7
Show file tree
Hide file tree
Showing 9 changed files with 23 additions and 13 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/auto-merge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ permissions:
jobs:
auto-merge:
runs-on: ubuntu-latest
if: ${{ (github.actor == 'dependabot[bot]' || github.actor == 'HavenDV') && github.repository_owner == 'tryAGI' }}
if: ${{ github.event.pull_request.draft == false && (github.actor == 'dependabot[bot]' || github.actor == 'HavenDV') && github.repository_owner == 'tryAGI' }}
steps:
- name: Dependabot metadata
if: ${{ github.actor == 'dependabot[bot]' }}
Expand Down
5 changes: 5 additions & 0 deletions .github/workflows/auto-update.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,11 @@ jobs:
git checkout -b ${{ steps.branch.outputs.branch_name }} origin/main
git rebase main
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 9.0.x

- name: Generate code
run: |
cd src/libs/Google.Gemini
Expand Down
12 changes: 9 additions & 3 deletions .github/workflows/mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,14 +33,20 @@ jobs:
- name: Setup Pages
uses: actions/configure-pages@v5

- name: Install dependencies
run: pip install mkdocs-material
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 9.0.x

- name: Generate docs
run: dotnet run --project src/helpers/GenerateDocs/GenerateDocs.csproj .

- name: Build with MkDocs
run: mkdocs build -d ./_site
run: |
python -m venv myenv
source myenv/bin/activate
pip install mkdocs-material
mkdocs build -d ./_site
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/pull-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ on:
jobs:
test:
name: Test
if: github.event.pull_request.draft == false
uses: HavenDV/workflows/.github/workflows/dotnet_build-test-publish.yml@main
with:
generate-build-number: false
Expand Down
2 changes: 1 addition & 1 deletion src/helpers/FixOpenApiSpec/FixOpenApiSpec.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<TargetFramework>net9.0</TargetFramework>
<OutputType>Exe</OutputType>
<LangVersion>preview</LangVersion>
<Nullable>enable</Nullable>
Expand Down
2 changes: 1 addition & 1 deletion src/helpers/GenerateDocs/GenerateDocs.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net8.0</TargetFramework>
<TargetFramework>net9.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
</PropertyGroup>

Expand Down
2 changes: 1 addition & 1 deletion src/helpers/TrimmingHelper/TrimmingHelper.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net8.0</TargetFramework>
<TargetFramework>net9.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>

<PublishTrimmed>true</PublishTrimmed>
Expand Down
4 changes: 2 additions & 2 deletions src/libs/Google.Gemini/Google.Gemini.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>netstandard2.0;net4.6.2;net6.0;net8.0</TargetFrameworks>
<TargetFrameworks>netstandard2.0;net4.6.2;net8.0;net9.0</TargetFrameworks>
</PropertyGroup>

<PropertyGroup Label="Nuget">
Expand All @@ -15,7 +15,7 @@
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="System.Text.Json" Version="8.0.5" />
<PackageReference Include="System.Text.Json" Version="9.0.0" />
</ItemGroup>

<ItemGroup Condition="'$(TargetFramework)' == 'net4.6.2'">
Expand Down
Original file line number Diff line number Diff line change
@@ -1,17 +1,15 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<TargetFramework>net9.0</TargetFramework>
</PropertyGroup>

<ItemGroup Label="Base packages">
<PackageReference Include="GitHubActionsTestLogger" Version="2.4.1">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.11.1" />
<PackageReference Include="MSTest.TestAdapter" Version="3.6.2" />
<PackageReference Include="MSTest.TestFramework" Version="3.6.2" />
<PackageReference Include="MSTest" Version="3.6.3" />
<PackageReference Include="FluentAssertions" Version="6.12.2" />
</ItemGroup>

Expand Down

0 comments on commit 1bb5ed7

Please sign in to comment.