json2bash
Advanced tools
Comparing version 0.2.0 to 0.2.1
@@ -110,2 +110,8 @@ #!/usr/bin/env node | ||
}) | ||
.option('exportprefix', { | ||
alias: ['x','export'], | ||
default: false, | ||
type: 'boolean', | ||
description: 'output with export before' | ||
}) | ||
.option('jsonx', { | ||
@@ -145,3 +151,3 @@ alias: ['j','jx'], | ||
var { var2Lower, prefix, onlyselected, fileout, debug, verbose,all,jsonx } = argv; | ||
var { var2Lower, prefix, onlyselected, fileout, debug, verbose,all,jsonx,exportprefix } = argv; | ||
var d = debug; | ||
@@ -262,4 +268,7 @@ | ||
var exportprefixVal = ""; | ||
if (exportprefix) exportprefixVal = "export "; | ||
if (!onlyselected) | ||
out[c] = "export " + outKey + "=\"" + value.trim() + "\""; | ||
out[c] = exportprefixVal + outKey + "=\"" + value.trim() + "\""; | ||
} | ||
@@ -266,0 +275,0 @@ else { |
{ | ||
"name": "json2bash", | ||
"version": "0.2.0", | ||
"version": "0.2.1", | ||
"description": "A CLI to export json object to bash env", | ||
@@ -5,0 +5,0 @@ "main": "json2bash.js", |
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
32924
858
0