Skip to content

Commit

Permalink
Update some workflow things
Browse files Browse the repository at this point in the history
  • Loading branch information
tmonck committed Sep 24, 2021
1 parent 8a0f10b commit 9855de3
Showing 1 changed file with 18 additions and 17 deletions.
35 changes: 18 additions & 17 deletions .github/workflows/dotnet.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,29 +8,30 @@ jobs:
build:
runs-on: windows-2022
steps:
- id: get-version
run: |
version=$(echo ${{github.ref}} | cut -d "/" -f3)
echo "::set-output name=version::$version"
- name: Print actual version
run: echo "${{steps.get-version.outputs.version}}"
- uses: actions/checkout@v2
- name: Setup .NET 5
uses: actions/setup-dotnet@v1
with:
dotnet-version: 5.0
- name: Setup .NET 6
uses: actions/setup-dotnet@v1
with:
dotnet-version: 6.0
include-prerelease: true
# - name: Install maui-check
# run: dotnet tool install -g Redth.Net.Maui.Check
# - name: maui-check
# run: /root/.dotnet/tools/maui-check --preview --ci --non-interactive --fix --skip xcode --skip vswin --skip vsmac --skip edgewebview2
- name: Install required workloads
run: dotnet workload install maui maui-mobile
- name: Install maui-check
run: dotnet tool install -g Redth.Net.Maui.Check
shell: pwsh
- name: maui-check
run: maui-check --preview --ci --non-interactive --fix --skip xcode --skip vswin --skip vsmac --skip edgewebview2
shell: pwsh
- name: Restore dependencies
run: dotnet restore
- name: Build
run: dotnet build --no-restore -p:PackageVersion=${{steps.get-version.outputs.version}}
- name: Pack
run: dotnet pack --include-symbols -o ./nuget
- name: Publish
run: dotnet nuget push .\nuget\*.nupkg -s "nuget.org" -k ${{ secrets.NUGET_API_KEY }}
run: |
$VERION=$env:GITHUB_REF.Substring($env:GITHUB_REF.LastIndexOf('/') + 1)
echo "PACKAGE VERSION: $VERSION"
dotnet build --no-restore -p:PackageVersion=$VERSION
# - name: Pack
# run: dotnet pack --include-symbols -o ./nuget
# - name: Publish
# run: dotnet nuget push .\nuget\*.nupkg -s "nuget.org" -k ${{ secrets.NUGET_API_KEY }}

0 comments on commit 9855de3

Please sign in to comment.