Skip to content

Commit fe41a25

Browse files
[Actions] Remove yaml warnings. (#24)
1 parent 921777b commit fe41a25

File tree

1 file changed

+55
-54
lines changed

1 file changed

+55
-54
lines changed

.github/workflows/deploy.yml

Lines changed: 55 additions & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
# yamllint disable rule:line-length
12
# deployes the build to nuget and github releases
23
name: Continuous Deployment
34

@@ -18,80 +19,80 @@ jobs:
1819
runs-on: ubuntu-latest
1920

2021
steps:
21-
- uses: actions/checkout@v4
22+
- uses: actions/checkout@v4
2223

23-
- name: Setup .NET
24-
uses: actions/setup-dotnet@v4
25-
with:
26-
dotnet-version: 8.0.x
24+
- name: Setup .NET
25+
uses: actions/setup-dotnet@v4
26+
with:
27+
dotnet-version: 8.0.x
2728

28-
- name: Set Version Variable
29-
if: ${{ github.ref_type == 'tag' }}
30-
env:
31-
TAG: ${{ github.ref_name }}
32-
run: echo "VERSION=${TAG#v}" >> $GITHUB_ENV
29+
- name: Set Version Variable
30+
if: ${{ github.ref_type == 'tag' }}
31+
env:
32+
TAG: ${{ github.ref_name }}
33+
run: echo "VERSION=${TAG#v}" >> $GITHUB_ENV
3334

34-
- name: Build project
35-
run: dotnet build -c Release /p:Version=$VERSION
35+
- name: Build project
36+
run: dotnet build -c Release /p:Version=$VERSION
3637

37-
- name: Create the package
38-
run: dotnet pack -c Release -o ${{ env.NuGetDirectory }} /p:PackageVersion=$VERSION
38+
- name: Create the package
39+
run: dotnet pack -c Release -o ${{ env.NuGetDirectory }} /p:PackageVersion=$VERSION
3940

40-
- name: Upload Package for Publishing
41-
uses: actions/upload-artifact@v4
42-
with:
43-
name: nuget
44-
if-no-files-found: error
45-
retention-days: 7
46-
path: ${{ env.NuGetDirectory }}/*.nupkg
41+
- name: Upload Package for Publishing
42+
uses: actions/upload-artifact@v4
43+
with:
44+
name: nuget
45+
if-no-files-found: error
46+
retention-days: 7
47+
path: ${{ env.NuGetDirectory }}/*.nupkg
4748

4849
validate-nuget:
4950
name: Validate nuget
5051
runs-on: ubuntu-latest
51-
needs: [ build ]
52+
needs: [build]
5253

5354
steps:
54-
- name: Setup .NET
55-
uses: actions/setup-dotnet@v4
56-
with:
57-
dotnet-version: 8.0.x
55+
- name: Setup .NET
56+
uses: actions/setup-dotnet@v4
57+
with:
58+
dotnet-version: 8.0.x
5859

59-
- name: Download built project
60-
uses: actions/download-artifact@v4
61-
with:
62-
name: nuget
63-
path: ${{ env.NuGetDirectory }}
60+
- name: Download built project
61+
uses: actions/download-artifact@v4
62+
with:
63+
name: nuget
64+
path: ${{ env.NuGetDirectory }}
6465

65-
- name: Install nuget validator
66-
run: dotnet tool update Meziantou.Framework.NuGetPackageValidation.Tool --global
66+
- name: Install nuget validator
67+
run: dotnet tool update Meziantou.Framework.NuGetPackageValidation.Tool --global
6768

68-
- name: Validate package
69-
shell: pwsh
70-
run: meziantou.validate-nuget-package (Get-ChildItem "${{ env.NuGetDirectory }}/*.nupkg") --excluded-rules IconMustBeSet
69+
- name: Validate package
70+
shell: pwsh
71+
run: meziantou.validate-nuget-package (Get-ChildItem "${{ env.NuGetDirectory }}/*.nupkg") --excluded-rules IconMustBeSet
7172

7273
github-publish:
73-
needs: [ build, validate-nuget ]
74+
needs: [build, validate-nuget]
7475
name: Publish to Github
7576
runs-on: ubuntu-latest
7677

7778
steps:
78-
- name: Download built project
79-
uses: actions/download-artifact@v4
80-
with:
81-
name: nuget
82-
path: ${{ env.NuGetDirectory }}
83-
84-
- name: Setup .NET
85-
uses: actions/setup-dotnet@v4
86-
with:
87-
dotnet-version: 8.0.x
88-
89-
- name: Publish NuGet package
90-
shell: pwsh
91-
run: |
92-
foreach($file in (Get-ChildItem "${{ env.NuGetDirectory }}" -Recurse -Include *.nupkg)) {
93-
dotnet nuget push $file --api-key "${{ secrets.GITHUB_TOKEN }}" --source https://nuget.pkg.github.com/mandel-macaque/index.json --skip-duplicate
94-
}
79+
- name: Download built project
80+
uses: actions/download-artifact@v4
81+
with:
82+
name: nuget
83+
path: ${{ env.NuGetDirectory }}
84+
85+
- name: Setup .NET
86+
uses: actions/setup-dotnet@v4
87+
with:
88+
dotnet-version: 8.0.x
89+
90+
- name: Publish NuGet package
91+
shell: pwsh
92+
run: |
93+
foreach($file in (Get-ChildItem "${{ env.NuGetDirectory }}" -Recurse -Include *.nupkg)) {
94+
dotnet nuget push $file --api-key "${{ secrets.GITHUB_TOKEN }}" --source https://nuget.pkg.github.com/mandel-macaque/index.json --skip-duplicate
95+
}
9596
9697
nuget-publish:
9798
needs: [ build, validate-nuget ]

0 commit comments

Comments
 (0)