Skip to content

Commit

Permalink
Merge pull request #28 from microsoft/release/vNext
Browse files Browse the repository at this point in the history
Merge release/vNext to main
  • Loading branch information
chrisnielsen-MS authored May 3, 2024
2 parents fa0f8ba + 3b39def commit 4f8576b
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 15 deletions.
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@microsoft/security-devops-azdevops-task-lib",
"version": "1.11.0",
"version": "1.12.0",
"description": "Microsoft Security DevOps for Azure DevOps task library.",
"author": "Microsoft Corporation",
"license": "MIT",
Expand Down
13 changes: 13 additions & 0 deletions src/msdo-client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,19 @@ async function setupEnvironment(): Promise<void> {

console.log('------------------------------------------------------------------------------');

// initialize the _msdo directory
let agentDirectory = path.join(process.env.AGENT_ROOTDIRECTORY, '_msdo');
tl.debug(`agentDirectory = ${agentDirectory}`);
common.ensureDirectory(agentDirectory);

let agentPackagesDirectory = process.env.MSDO_PACKAGES_DIRECTORY;
if (!agentPackagesDirectory) {
agentPackagesDirectory = path.join(agentDirectory, 'packages');
tl.debug(`agentPackagesDirectory = ${agentPackagesDirectory}`);
common.ensureDirectory(agentPackagesDirectory);
process.env.MSDO_PACKAGES_DIRECTORY = agentPackagesDirectory;
}

if (!process.env.MSDO_FILEPATH) {
let cliVersion = resolveCliVersion();
await installer.install(cliVersion);
Expand Down
12 changes: 0 additions & 12 deletions src/msdo-installer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,19 +31,7 @@ export async function install(cliVersion: string): Promise<void> {

let packageName = resolvePackageName();

// initialize the _msdo directory
let agentDirectory = path.join(process.env.AGENT_ROOTDIRECTORY, '_msdo');
tl.debug(`agentDirectory = ${agentDirectory}`);
common.ensureDirectory(agentDirectory);

let agentPackagesDirectory = process.env.MSDO_PACKAGES_DIRECTORY;
if (!agentPackagesDirectory) {
agentPackagesDirectory = path.join(agentDirectory, 'packages');
tl.debug(`agentPackagesDirectory = ${agentPackagesDirectory}`);
common.ensureDirectory(agentPackagesDirectory);
process.env.MSDO_PACKAGES_DIRECTORY = agentPackagesDirectory;
}

let agentVersionsDirectory = path.join(agentDirectory, 'versions');
tl.debug(`agentVersionsDirectory = ${agentVersionsDirectory}`);
common.ensureDirectory(agentVersionsDirectory);
Expand Down

0 comments on commit 4f8576b

Please sign in to comment.