Skip to content

Commit

Permalink
feat(dotnet): add a method to install local tools
Browse files Browse the repository at this point in the history
Add a method that future builders can use to install additional tools

Fixes #44
  • Loading branch information
Ben Callaghan committed May 18, 2021
1 parent 996aaee commit 6ab5d4a
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions packages/dotnet/src/lib/core/dotnet.client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,11 @@ export class DotNetClient {
return this.logAndExecute(cmd);
}

installTool(tool: string): Buffer {
const cmd = `${this.cliCommand.command} tool install ${tool}`;
return this.logAndExecute(cmd);
}

private logAndExecute(cmd: string): Buffer {
console.log(`Executing Command: ${cmd}`);
return execSync(cmd, { stdio: 'inherit' });
Expand Down

0 comments on commit 6ab5d4a

Please sign in to comment.