File tree Expand file tree Collapse file tree 4 files changed +14
-5
lines changed Expand file tree Collapse file tree 4 files changed +14
-5
lines changed Original file line number Diff line number Diff line change 19
19
- uses : actions/checkout@master
20
20
- uses : actions/setup-dotnet@v1
21
21
with :
22
- version : ' 2.2.103' // SDK Version to use.
22
+ dotnet- version : ' 2.2.103' // SDK Version to use.
23
23
- run : dotnet build <my project>
24
24
` ` `
25
25
37
37
- name : Setup dotnet
38
38
uses : actions/setup-dotnet@v1
39
39
with :
40
- version : ${{ matrix.dotnet }}
40
+ dotnet- version : ${{ matrix.dotnet }}
41
41
- run : dotnet build <my project>
42
42
` ` `
43
43
Original file line number Diff line number Diff line change @@ -2,8 +2,11 @@ name: 'Setup Dotnet environment'
2
2
description : ' Setup a Dotnet environment and add it to the PATH, additionally providing proxy support'
3
3
author : ' GitHub'
4
4
inputs :
5
- version :
5
+ dotnet- version :
6
6
description : ' SDK version to use. E.g. 2.2.104'
7
+ # Deprecated option, do not use. Will not be supported after October 1, 2019
8
+ version :
9
+ description : ' Deprecated. Use dotnet-version instead. Will not be supported after October 1, 2019'
7
10
runs :
8
11
using : ' node12'
9
12
main : ' lib/setup-dotnet.js'
Original file line number Diff line number Diff line change @@ -25,7 +25,10 @@ function run() {
25
25
// Version is optional. If supplied, install / use from the tool cache
26
26
// If not supplied then task is still used to setup proxy, auth, etc...
27
27
//
28
- const version = core . getInput ( 'version' ) ;
28
+ let version = core . getInput ( 'version' ) ;
29
+ if ( ! version ) {
30
+ version = core . getInput ( 'dotnet-version' ) ;
31
+ }
29
32
if ( version ) {
30
33
const dotnetInstaller = new installer . DotnetCoreInstaller ( version ) ;
31
34
yield dotnetInstaller . installDotnet ( ) ;
Original file line number Diff line number Diff line change @@ -8,7 +8,10 @@ async function run() {
8
8
// Version is optional. If supplied, install / use from the tool cache
9
9
// If not supplied then task is still used to setup proxy, auth, etc...
10
10
//
11
- const version = core . getInput ( 'version' ) ;
11
+ let version = core . getInput ( 'version' ) ;
12
+ if ( ! version ) {
13
+ version = core . getInput ( 'dotnet-version' ) ;
14
+ }
12
15
if ( version ) {
13
16
const dotnetInstaller = new installer . DotnetCoreInstaller ( version ) ;
14
17
await dotnetInstaller . installDotnet ( ) ;
You can’t perform that action at this time.
0 commit comments