Skip to content

Commit

Permalink
Update GitHub Actions
Browse files Browse the repository at this point in the history
  • Loading branch information
0xfeeddeadbeef committed Nov 25, 2022
1 parent 9c91c3b commit a78359d
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 24 deletions.
5 changes: 2 additions & 3 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,10 +56,9 @@ jobs:
# queries: ./path/to/local/query, your-org/your-repo/queries@main

- name: Setup .NET SDK
uses: actions/setup-dotnet@v2
uses: actions/setup-dotnet@v3
with:
dotnet-version: 6.0.x
include-prerelease: false
global-json-file: global.json

# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/dependency-review.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,4 @@ jobs:
- name: 'Checkout Repository'
uses: actions/checkout@v3
- name: 'Dependency Review'
uses: actions/dependency-review-action@v1
uses: actions/dependency-review-action@v3
7 changes: 3 additions & 4 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,10 @@ jobs:
with:
fetch-depth: 1

- name: Setup .NET 6 SDK
uses: actions/setup-dotnet@v2
- name: Setup .NET SDK
uses: actions/setup-dotnet@v3
with:
dotnet-version: 6.0.x
include-prerelease: false
global-json-file: global.json

- name: Restore
run: dotnet restore -p:Configuration=Release
Expand Down
25 changes: 9 additions & 16 deletions .github/workflows/nuget.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,34 +29,27 @@ jobs:
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 10
fetch-depth: 0

- name: Setup .NET 6 SDK
uses: actions/setup-dotnet@v2
- name: Setup .NET SDK
uses: actions/setup-dotnet@v3
with:
dotnet-version: 6.0.x
include-prerelease: false

# Use vanilla NuGet.exe because dotnet nuget command has a bug: it ignores --source parameter
- name: Setup NuGet.exe
uses: NuGet/setup-nuget@v1
with:
nuget-api-key: ${{ secrets.NUGET_API_KEY }}
nuget-version: latest
nuget-api-key-source: 'https://api.nuget.org/v3/index.json'
global-json-file: global.json

- name: Restore
run: dotnet restore -p:Configuration=Release

- name: Build
run: dotnet build -c Release --no-restore -p:SourceRevisionId=$(git rev-parse --short $env:GITHUB_SHA)
run: |
$revisionId = $(git rev-parse --short $env:GITHUB_SHA)
dotnet build -c Release --no-restore "-p:SourceRevisionId=$revisionId"
# There are no tests yet.
#- name: Test
# run: dotnet test -c Release --no-restore --no-build --verbosity normal

- name: Push Jws
run: nuget push "src\TBC.OpenBanking.Jws\src\bin\Release\*.nupkg" -NonInteractive -SkipDuplicate -Source "https://api.nuget.org/v3/index.json" -NoSymbols -ForceEnglishOutput
run: dotnet nuget push "src\TBC.OpenBanking.Jws\src\bin\Release\*.nupkg" -k "${{ secrets.NUGET_API_KEY }}" -s "https://api.nuget.org/v3/index.json" -n --skip-duplicate --force-english-output

- name: Push Jws.Http
run: nuget push "src\TBC.OpenBanking.Jws.Http\src\bin\Release\*.nupkg" -NonInteractive -SkipDuplicate -Source "https://api.nuget.org/v3/index.json" -NoSymbols -ForceEnglishOutput
run: dotnet nuget push "src\TBC.OpenBanking.Jws.Http\src\bin\Release\*.nupkg" -k "${{ secrets.NUGET_API_KEY }}" -s "https://api.nuget.org/v3/index.json" -n --skip-duplicate --force-english-output

0 comments on commit a78359d

Please sign in to comment.