-
Notifications
You must be signed in to change notification settings - Fork 36
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
3 changed files
with
57 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
const Command = require('../../Command'); | ||
const componentsRoot = require('../root/components.cmd'); | ||
const helper = require('../hybrid/helper'); | ||
|
||
const command = new Command({ | ||
command: 'download', | ||
parent: componentsRoot, | ||
description: 'Download Codefresh CLI components', | ||
webDocs: { | ||
category: 'Components', | ||
title: 'Download', | ||
}, | ||
builder: (yargs) => yargs | ||
.env('CF_ARG_') // this means that every process.env.CF_ARG_* will be passed to argv | ||
.option('location', { | ||
describe: 'Override download folder location. Default: ~/.Codefresh', | ||
}) | ||
.option('components', { | ||
describe: 'Components. List of [stevedore, venona, argocd-agent, codefresh]', | ||
}), | ||
handler: async (argv) => { | ||
console.log('Downloading components'); | ||
const { location, components } = argv; | ||
await helper.downloadComponents(location, components); | ||
}, | ||
}); | ||
|
||
module.exports = command; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters