Skip to content

Commit

Permalink
build: update build script
Browse files Browse the repository at this point in the history
  • Loading branch information
cxfksword committed Nov 24, 2023
1 parent d0f8f1e commit ea4788f
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 5 deletions.
6 changes: 5 additions & 1 deletion .github/workflows/beta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ env:

jobs:
build:
runs-on: ubuntu-22.04
runs-on: ubuntu-latest
name: Build & Release

steps:
Expand All @@ -20,8 +20,12 @@ jobs:
run: git fetch --depth=1 origin +refs/tags/*:refs/tags/*
- name: Setup dotnet
uses: actions/setup-dotnet@v3
id: dotnet
with:
dotnet-version: ${{ env.dotnet-version }}
- name: Change default dotnet version
run: |
echo '{"sdk":{"version": "${{ steps.dotnet.outputs.dotnet-version }}"}}' > ./global.json
- name: Initialize workflow variables
id: vars
run: |
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,9 @@ jobs:
id: dotnet
with:
dotnet-version: 6.0.x
- name: force dotnet version
- name: Change default dotnet version
run: |
echo '{"sdk":{"version": "${{ steps.dotnet.outputs.dotnet-version }}"}}' > ./global.json
- name: print
run: dotnet --list-sdks && dotnet --info
- name: Install dependencies
run: dotnet restore
- name: Build
Expand Down
6 changes: 5 additions & 1 deletion .github/workflows/publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ env:

jobs:
build:
runs-on: ubuntu-22.04
runs-on: ubuntu-latest
name: Build & Release

steps:
Expand All @@ -21,8 +21,12 @@ jobs:
run: git fetch --depth=1 origin +refs/tags/*:refs/tags/*
- name: Setup dotnet
uses: actions/setup-dotnet@v3
id: dotnet
with:
dotnet-version: ${{ env.dotnet-version }}
- name: Change default dotnet version
run: |
echo '{"sdk":{"version": "${{ steps.dotnet.outputs.dotnet-version }}"}}' > ./global.json
- name: Setup python
uses: actions/setup-python@v2
with:
Expand Down
1 change: 1 addition & 0 deletions global.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"sdk":{"version": "${{ steps.dotnet.outputs.dotnet-version }}"}}

0 comments on commit ea4788f

Please sign in to comment.