File tree 3 files changed +51
-0
lines changed
3 files changed +51
-0
lines changed Original file line number Diff line number Diff line change 5
5
branches :
6
6
- dev
7
7
8
+ env :
9
+ DOTNET_SKIP_FIRST_TIME_EXPERIENCE : 1
10
+ DOTNET_NOLOGO : true
11
+
8
12
jobs :
9
13
publish :
10
14
25
29
echo "VERSION=$version" | Out-File -FilePath $Env:GITHUB_ENV -Encoding utf8 -Append
26
30
shell : pwsh
27
31
32
+ - name : Add version to global.json
33
+ run : |
34
+ $version = "7.0.406"
35
+ $globalJsonPath = "global.json"
36
+ $globalJson = Get-Content -Raw -Path $globalJsonPath | ConvertFrom-Json
37
+ if ($null -eq $globalJson.sdk.version) {
38
+ $globalJson.sdk | Add-Member -Type NoteProperty -Name version -Value $version
39
+ } else {
40
+ $globalJson.sdk.version = $version
41
+ }
42
+ $globalJson | ConvertTo-Json -Depth 10 | Set-Content -Path $globalJsonPath
43
+ shell : pwsh
44
+
28
45
- name : Install .NET Core
29
46
uses : actions/setup-dotnet@v4
30
47
with :
Original file line number Diff line number Diff line change 5
5
tags :
6
6
- ' releases/*'
7
7
8
+ env :
9
+ DOTNET_SKIP_FIRST_TIME_EXPERIENCE : 1
10
+ DOTNET_NOLOGO : true
11
+
8
12
jobs :
9
13
publish :
10
14
runs-on : ubuntu-latest
27
31
echo "VERSION=$version" | Out-File -FilePath $Env:GITHUB_ENV -Encoding utf8 -Append
28
32
shell : pwsh
29
33
34
+ - name : Add version to global.json
35
+ run : |
36
+ $version = "7.0.406"
37
+ $globalJsonPath = "global.json"
38
+ $globalJson = Get-Content -Raw -Path $globalJsonPath | ConvertFrom-Json
39
+ if ($null -eq $globalJson.sdk.version) {
40
+ $globalJson.sdk | Add-Member -Type NoteProperty -Name version -Value $version
41
+ } else {
42
+ $globalJson.sdk.version = $version
43
+ }
44
+ $globalJson | ConvertTo-Json -Depth 10 | Set-Content -Path $globalJsonPath
45
+ shell : pwsh
46
+
30
47
- name : Install .NET Core
31
48
uses : actions/setup-dotnet@v4
32
49
with :
Original file line number Diff line number Diff line change 10
10
- master
11
11
- dev
12
12
13
+ env :
14
+ DOTNET_SKIP_FIRST_TIME_EXPERIENCE : 1
15
+ DOTNET_NOLOGO : true
16
+
13
17
jobs :
14
18
build :
15
19
28
32
with :
29
33
dotnet-version : ${{ matrix.dotnet }}
30
34
35
+ - name : Add version to global.json
36
+ run : |
37
+ $version = "${{ matrix.dotnet }}"
38
+ $globalJsonPath = "global.json"
39
+ $globalJson = Get-Content -Raw -Path $globalJsonPath | ConvertFrom-Json
40
+ if ($null -eq $globalJson.sdk.version) {
41
+ $globalJson.sdk | Add-Member -Type NoteProperty -Name version -Value $version
42
+ } else {
43
+ $globalJson.sdk.version = $version
44
+ }
45
+ $globalJson | ConvertTo-Json -Depth 10 | Set-Content -Path $globalJsonPath
46
+ shell : pwsh
47
+
31
48
- name : Install local tools
32
49
run : dotnet tool restore
33
50
You can’t perform that action at this time.
0 commit comments