@cocreate/cli
Advanced tools
Comparing version 1.31.0 to 1.31.1
@@ -0,1 +1,8 @@ | ||
## [1.31.1](https://github.com/CoCreate-app/CoCreate-cli/compare/v1.31.0...v1.31.1) (2023-06-10) | ||
### Bug Fixes | ||
* Update file dependency version and add console colors, minor code refactoring to CoCreate Config. ([c836d3a](https://github.com/CoCreate-app/CoCreate-cli/commit/c836d3ae070c41704300f5af646b708a01f8f63b)) | ||
# [1.31.0](https://github.com/CoCreate-app/CoCreate-cli/compare/v1.30.0...v1.31.0) (2023-06-09) | ||
@@ -2,0 +9,0 @@ |
{ | ||
"name": "@cocreate/cli", | ||
"version": "1.31.0", | ||
"version": "1.31.1", | ||
"description": "Polyrepo management bash CLI tool. Run all git commands and yarn commands on multiple repositories. Also includes a few custom macros for cloning, installing, etc.", | ||
@@ -62,3 +62,3 @@ "keywords": [ | ||
"@cocreate/docs": "^1.8.2", | ||
"@cocreate/file": "^1.0.0", | ||
"@cocreate/file": "^1.1.0", | ||
"colors": "latest", | ||
@@ -65,0 +65,0 @@ "glob": "^7.1.7", |
@@ -7,2 +7,3 @@ #!/usr/bin/env node | ||
const addMeta = require('./addMeta'); | ||
const colors = require('colors'); | ||
@@ -61,3 +62,3 @@ | ||
console.warn(`using ${packageJsonPath} configuration`.yellow); | ||
} | ||
} | ||
// else { | ||
@@ -64,0 +65,0 @@ // console.error(`a configuration file can not be found`.red); |
@@ -43,5 +43,24 @@ const readline = require('readline'); | ||
for (let i = 0; i < items.length; i++) { | ||
const { key, prompt, choices } = items[i]; | ||
let { key, prompt, choices } = items[i]; | ||
if (!key) { | ||
if (!prompt && prompt !== '' || !choices) continue; | ||
for (let choice of Object.keys(choices)) { | ||
// if (!Array.isArray(choiceItems)) { | ||
// choiceItems = [choiceItems]; | ||
// } | ||
// for (let choice of choiceItems) { | ||
let choiceKey = choices[choice].key | ||
if (process.env[choiceKey]) { | ||
config[choiceKey] = process.env[choiceKey]; | ||
return; | ||
} else if (localConfig[choiceKey]) { | ||
config[choiceKey] = localConfig[choiceKey]; | ||
return; | ||
} else if (globalConfig[choiceKey]) { | ||
config[choiceKey] = globalConfig[choiceKey]; | ||
return; | ||
} | ||
} | ||
// } | ||
const answer = await promptForInput(prompt || `${key}: `); | ||
@@ -48,0 +67,0 @@ const choice = choices[answer]; |
@@ -1,4 +0,1 @@ | ||
const crud = require('@cocreate/crud-client') | ||
const mime = require('mime-types') | ||
const fs = require('fs'); | ||
const file = require('@cocreate/file') | ||
@@ -5,0 +2,0 @@ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
170856
2398
24
42
Updated@cocreate/file@^1.1.0