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

INFRA: Update Net Version 8 #35

Merged
merged 2 commits into from
Oct 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
20 changes: 13 additions & 7 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,6 @@ jobs:
with:
github-token: ${{ secrets.PAT_FOR_TAGGING }}
script: >2

if (!context.payload.pull_request) {
console.log('Not a pull request, skipping label script routine');
return;
}

const prefixes = [
'INFRA:',
Expand Down Expand Up @@ -74,10 +69,21 @@ jobs:
'BUSINESS:'
];


const pullRequest = context.payload.pull_request;


if (!pullRequest) {
console.log('No pull request context available.');
return;
}


const title = context.payload.pull_request.title;

const existingLabels = context.payload.pull_request.labels.map(label => label.name);


for (const prefix of prefixes) {
if (title.startsWith(prefix)) {
const label = prefix.slice(0, -1);
Expand All @@ -101,7 +107,7 @@ jobs:
- name: Setup .Net
uses: actions/setup-dotnet@v3
with:
dotnet-version: 7.0.201
dotnet-version: 8.0.402
- name: Restore
run: dotnet restore
- name: Build
Expand Down Expand Up @@ -208,4 +214,4 @@ jobs:
- name: Pack NuGet Package
run: dotnet pack --configuration Release --include-symbols
- name: Push NuGet Package
run: dotnet nuget push **/bin/Release/**/*.nupkg --source https://api.nuget.org/v3/index.json --api-key ${{ secrets.NUGET_ACCESS }} --skip-duplicate
run: dotnet nuget push **/bin/Release/**/*.nupkg --source https://api.nuget.org/v3/index.json --api-key ${{ secrets.NUGET_ACCESS }} --skip-duplicate
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@

With = new TargetDotNetVersionV3
{
DotNetVersion = "7.0.201"
DotNetVersion = "8.0.402"
}
},

Expand Down Expand Up @@ -113,11 +113,11 @@
};

string buildScriptPath = "../../../../.github/workflows/build.yml";
string directoryPath = Path.GetDirectoryName(buildScriptPath);

Check warning on line 116 in STX.SPAL.Core.Infrastructure.Build/Services/ScriptGenerationService.cs

View workflow job for this annotation

GitHub Actions / build

Converting null literal or possible null value to non-nullable type.

Check warning on line 116 in STX.SPAL.Core.Infrastructure.Build/Services/ScriptGenerationService.cs

View workflow job for this annotation

GitHub Actions / build

Converting null literal or possible null value to non-nullable type.

Check warning on line 116 in STX.SPAL.Core.Infrastructure.Build/Services/ScriptGenerationService.cs

View workflow job for this annotation

GitHub Actions / build

Converting null literal or possible null value to non-nullable type.

Check warning on line 116 in STX.SPAL.Core.Infrastructure.Build/Services/ScriptGenerationService.cs

View workflow job for this annotation

GitHub Actions / build

Converting null literal or possible null value to non-nullable type.

if (!Directory.Exists(directoryPath))
{
Directory.CreateDirectory(directoryPath);

Check warning on line 120 in STX.SPAL.Core.Infrastructure.Build/Services/ScriptGenerationService.cs

View workflow job for this annotation

GitHub Actions / build

Possible null reference argument for parameter 'path' in 'DirectoryInfo Directory.CreateDirectory(string path)'.

Check warning on line 120 in STX.SPAL.Core.Infrastructure.Build/Services/ScriptGenerationService.cs

View workflow job for this annotation

GitHub Actions / build

Possible null reference argument for parameter 'path' in 'DirectoryInfo Directory.CreateDirectory(string path)'.

Check warning on line 120 in STX.SPAL.Core.Infrastructure.Build/Services/ScriptGenerationService.cs

View workflow job for this annotation

GitHub Actions / build

Possible null reference argument for parameter 'path' in 'DirectoryInfo Directory.CreateDirectory(string path)'.

Check warning on line 120 in STX.SPAL.Core.Infrastructure.Build/Services/ScriptGenerationService.cs

View workflow job for this annotation

GitHub Actions / build

Possible null reference argument for parameter 'path' in 'DirectoryInfo Directory.CreateDirectory(string path)'.
}

adotNetClient.SerializeAndWriteToFile(
Expand Down
Loading