File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11{
22 "name" : " @microsoft/security-devops-azdevops-task-lib" ,
3- "version" : " 1.11 .0" ,
3+ "version" : " 1.12 .0" ,
44 "description" : " Microsoft Security DevOps for Azure DevOps task library." ,
55 "author" : " Microsoft Corporation" ,
66 "license" : " MIT" ,
Original file line number Diff line number Diff line change @@ -24,6 +24,19 @@ async function setupEnvironment(): Promise<void> {
2424
2525 console . log ( '------------------------------------------------------------------------------' ) ;
2626
27+ // initialize the _msdo directory
28+ let agentDirectory = path . join ( process . env . AGENT_ROOTDIRECTORY , '_msdo' ) ;
29+ tl . debug ( `agentDirectory = ${ agentDirectory } ` ) ;
30+ common . ensureDirectory ( agentDirectory ) ;
31+
32+ let agentPackagesDirectory = process . env . MSDO_PACKAGES_DIRECTORY ;
33+ if ( ! agentPackagesDirectory ) {
34+ agentPackagesDirectory = path . join ( agentDirectory , 'packages' ) ;
35+ tl . debug ( `agentPackagesDirectory = ${ agentPackagesDirectory } ` ) ;
36+ common . ensureDirectory ( agentPackagesDirectory ) ;
37+ process . env . MSDO_PACKAGES_DIRECTORY = agentPackagesDirectory ;
38+ }
39+
2740 if ( ! process . env . MSDO_FILEPATH ) {
2841 let cliVersion = resolveCliVersion ( ) ;
2942 await installer . install ( cliVersion ) ;
Original file line number Diff line number Diff line change @@ -31,19 +31,7 @@ export async function install(cliVersion: string): Promise<void> {
3131
3232 let packageName = resolvePackageName ( ) ;
3333
34- // initialize the _msdo directory
3534 let agentDirectory = path . join ( process . env . AGENT_ROOTDIRECTORY , '_msdo' ) ;
36- tl . debug ( `agentDirectory = ${ agentDirectory } ` ) ;
37- common . ensureDirectory ( agentDirectory ) ;
38-
39- let agentPackagesDirectory = process . env . MSDO_PACKAGES_DIRECTORY ;
40- if ( ! agentPackagesDirectory ) {
41- agentPackagesDirectory = path . join ( agentDirectory , 'packages' ) ;
42- tl . debug ( `agentPackagesDirectory = ${ agentPackagesDirectory } ` ) ;
43- common . ensureDirectory ( agentPackagesDirectory ) ;
44- process . env . MSDO_PACKAGES_DIRECTORY = agentPackagesDirectory ;
45- }
46-
4735 let agentVersionsDirectory = path . join ( agentDirectory , 'versions' ) ;
4836 tl . debug ( `agentVersionsDirectory = ${ agentVersionsDirectory } ` ) ;
4937 common . ensureDirectory ( agentVersionsDirectory ) ;
You can’t perform that action at this time.
0 commit comments