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

CC-1541: Update .NET version to 9.0 #110

Merged
merged 1 commit into from
Dec 12, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
2 changes: 1 addition & 1 deletion compiled_starters/csharp/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ Time to move on to the next stage!

Note: This section is for stages 2 and beyond.

1. Ensure you have `dotnet (8.0)` installed locally
1. Ensure you have `dotnet (9.0)` installed locally
1. Run `./your_program.sh` to run your program, which is implemented in
`src/Server.cs`.
1. Commit your changes and run `git push origin master` to submit your solution
Expand Down
2 changes: 1 addition & 1 deletion compiled_starters/csharp/codecrafters-http-server.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>
<RootNamespace>codecrafters_http_server</RootNamespace>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
Expand Down
4 changes: 2 additions & 2 deletions compiled_starters/csharp/codecrafters.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,5 @@ debug: false
# Use this to change the C# version used to run your code
# on Codecrafters.
#
# Available versions: dotnet-8.0
language_pack: dotnet-8.0
# Available versions: dotnet-9.0
language_pack: dotnet-9.0
17 changes: 17 additions & 0 deletions dockerfiles/dotnet-9.0.Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# syntax=docker/dockerfile:1.7-labs
FROM mcr.microsoft.com/dotnet/sdk:9.0-alpine

WORKDIR /app

# Re-build image if any of these files change
ENV CODECRAFTERS_DEPENDENCY_FILE_PATHS="codecrafters-redis.csproj,codecrafters-redis.sln"

# .git & README.md are unique per-repository. We ignore them on first copy to prevent cache misses
COPY --exclude=.git --exclude=README.md . /app

# This saves nuget packages to ~/.nuget
RUN dotnet build --configuration Release .

# Legacy support, remove in the next version of this dockerfile
RUN echo "cd \${CODECRAFTERS_REPOSITORY_DIR} && dotnet build --configuration Release ." > /codecrafters-precompile.sh
RUN chmod +x /codecrafters-precompile.sh
2 changes: 1 addition & 1 deletion solutions/csharp/01-at4/code/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ Time to move on to the next stage!

Note: This section is for stages 2 and beyond.

1. Ensure you have `dotnet (8.0)` installed locally
1. Ensure you have `dotnet (9.0)` installed locally
1. Run `./your_program.sh` to run your program, which is implemented in
`src/Server.cs`.
1. Commit your changes and run `git push origin master` to submit your solution
Expand Down
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>
<RootNamespace>codecrafters_http_server</RootNamespace>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
Expand Down
4 changes: 2 additions & 2 deletions solutions/csharp/01-at4/code/codecrafters.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,5 @@ debug: false
# Use this to change the C# version used to run your code
# on Codecrafters.
#
# Available versions: dotnet-8.0
language_pack: dotnet-8.0
# Available versions: dotnet-9.0
language_pack: dotnet-9.0
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>
<RootNamespace>codecrafters_http_server</RootNamespace>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
Expand Down
2 changes: 1 addition & 1 deletion starter_templates/csharp/config.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
attributes:
required_executable: dotnet (8.0)
required_executable: dotnet (9.0)
user_editable_file: src/Server.cs
Loading