File tree Expand file tree Collapse file tree 6 files changed +39
-11
lines changed Expand file tree Collapse file tree 6 files changed +39
-11
lines changed Original file line number Diff line number Diff line change 99
99
- task : NodeTool@0
100
100
displayName : Install Autorest
101
101
inputs :
102
- versionSpec : ' 14.17.1 '
102
+ versionSpec : ' 18.20.7 '
103
103
command : custom
104
104
verbose : false
105
105
customCommand : install autorest@latest
@@ -109,7 +109,11 @@ jobs:
109
109
targetType : inline
110
110
script : " $env:NODE_OPTIONS=\" --max-old-space-size=65536\" "
111
111
pwsh : true
112
-
112
+ - task : Npm@1
113
+ displayName : Install tsp client
114
+ inputs :
115
+ command : custom
116
+ customCommand :
install -g @azure-tools/[email protected]
113
117
- task : PowerShell@2
114
118
displayName : ' Build'
115
119
inputs :
Original file line number Diff line number Diff line change 47
47
- task : NodeTool@0
48
48
displayName : Install Autorest
49
49
inputs :
50
- versionSpec : ' 14.17.1 '
50
+ versionSpec : ' 18.20.7 '
51
51
command : custom
52
52
verbose : false
53
53
customCommand : install autorest@latest
57
57
targetType : inline
58
58
script : " $env:NODE_OPTIONS=\" --max-old-space-size=65536\" "
59
59
pwsh : true
60
+ - task : Npm@1
61
+ displayName : Install tsp client
62
+ inputs :
63
+ command : custom
64
+ customCommand :
install -g @azure-tools/[email protected]
60
65
- task : PowerShell@2
61
66
displayName : ' Build'
62
67
inputs :
Original file line number Diff line number Diff line change 27
27
- task : NodeTool@0
28
28
displayName : Install Autorest
29
29
inputs :
30
- versionSpec : ' 14.17.1 '
30
+ versionSpec : ' 18.20.7 '
31
31
command : custom
32
32
verbose : false
33
33
customCommand : install autorest@latest
37
37
targetType : inline
38
38
script : " $env:NODE_OPTIONS=\" --max-old-space-size=65536\" "
39
39
pwsh : true
40
+ - task : Npm@1
41
+ displayName : Install tsp client
42
+ inputs :
43
+ command : custom
44
+ customCommand :
install -g @azure-tools/[email protected]
40
45
- task : PowerShell@2
41
46
displayName : ' Build'
42
47
inputs :
Original file line number Diff line number Diff line change 11
11
- task : NodeTool@0
12
12
displayName : Install autorest
13
13
inputs :
14
- versionSpec : ' 14.17.1 '
14
+ versionSpec : ' 18.20.7 '
15
15
command : custom
16
16
verbose : false
17
17
customCommand : install autorest@latest
@@ -21,7 +21,11 @@ steps:
21
21
targetType : inline
22
22
script : " $env:NODE_OPTIONS=\" --max-old-space-size=65536\" "
23
23
pwsh : true
24
-
24
+ - task : Npm@1
25
+ displayName : Install tsp client
26
+ inputs :
27
+ command : custom
28
+ customCommand :
install -g @azure-tools/[email protected]
25
29
- task : UseDotNet@2
26
30
displayName : ' Use .NET Core sdk 6.0.x'
27
31
inputs :
Original file line number Diff line number Diff line change 43
43
- task : NodeTool@0
44
44
displayName : Install Autorest
45
45
inputs :
46
- versionSpec : ' 14.17.1 '
46
+ versionSpec : ' 18.20.7 '
47
47
command : custom
48
48
verbose : false
49
49
customCommand : install autorest@latest
53
53
targetType : inline
54
54
script : " $env:NODE_OPTIONS=\" --max-old-space-size=65536\" "
55
55
pwsh : true
56
+ - task : Npm@1
57
+ displayName : Install tsp client
58
+ inputs :
59
+ command : custom
60
+ customCommand :
install -g @azure-tools/[email protected]
56
61
- task : PowerShell@2
57
62
displayName : ' Build'
58
63
inputs :
Original file line number Diff line number Diff line change @@ -86,12 +86,17 @@ function Invoke-SubModuleGeneration {
86
86
)
87
87
Write-Host " ----------Start code generation for $GenerateDirectory ----------" - ForegroundColor DarkGreen
88
88
Set-Location - Path $GenerateDirectory
89
- if ($IsInvokedByPipeline ) {
90
- npx autorest -- max- memory- size= 8192 >> $GenerateLog
89
+ $tspLocationPath = Join-Path $GenerateDirectory " tsp-location.yaml"
90
+ if (Test-Path $tspLocationPath ) {
91
+ tsp- client update >> $GenerateLog
91
92
} else {
92
- autorest -- max- memory- size= 8192 >> $GenerateLog
93
+ if ($IsInvokedByPipeline ) {
94
+ npx autorest -- max- memory- size= 8192 >> $GenerateLog
95
+ } else {
96
+ autorest -- max- memory- size= 8192 >> $GenerateLog
97
+ }
93
98
}
94
-
99
+
95
100
if ($lastexitcode -ne 0 ) {
96
101
return $false
97
102
} else {
You can’t perform that action at this time.
0 commit comments