re-arranged files

This commit is contained in:
Artur Stolear
2020-01-25 23:46:37 +02:00
parent 57e92d55a3
commit 18ac32b856
26 changed files with 2978 additions and 2278 deletions

View File

@@ -0,0 +1,23 @@
import { container, IBuildAgent, TYPES, SetupOptions } from "../../core/common";
import { IGitReleaseManagerTool, GitReleaseManagerTool } from "../../core/gitreleasemanager";
container.bind<IGitReleaseManagerTool>(TYPES.IGitReleaseManagerTool).to(GitReleaseManagerTool);
const gitReleaseManagerTool = container.get<IGitReleaseManagerTool>(TYPES.IGitReleaseManagerTool);
const buildAgent = container.get<IBuildAgent>(TYPES.IBuildAgent);
export async function setup() {
try {
buildAgent.exportVariable("DOTNET_CLI_TELEMETRY_OPTOUT", "1");
const versionSpec = buildAgent.getInput(SetupOptions.versionSpec);
const includePrerelease = buildAgent.getBooleanInput(SetupOptions.includePrerelease);
await gitReleaseManagerTool.install(versionSpec, includePrerelease);
buildAgent.setSucceeded("GitVersionManager installed successfully", true);
} catch (error) {
buildAgent.setFailed(error.message, true);
}
}

View File

@@ -1,4 +1,4 @@
import "reflect-metadata";
import { setup } from "../../core/gitreleasemanager";
import { setup } from "./main";
setup();