Skip to content

Toshinori-Hayashi/json2shvars

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

23 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

GitHub GitHub code size in bytes

json2shvars

Library of Register json to Shellscript variables

ko1nksm/shdotenv is recommended for .env

requirement Lib

how to use

Please place the following files.

  • json2shvars.lib..sh
  • lib/makrj.sh
  • lib/parsrj.sh

Please set the following variables.

  • _J2SVLIB
    • Path to makrj.sh, parsrj.sh

sample

sample code

# set 3rdparty Lib path
_J2SVLIB="Path/to/lib"

# include lib
_FNCFILE="${_J2SVDIR}/json2shvars.lib.sh"
. ${_FNCFILE}

# make configuration, load and delete
_configfile=$(mkConf ${_jsonfile} ${_tag})
. ${_configfile}
rm ${_configfile}

run include sample.sh

sh ./sample.sh sample.json staging _TOKEN

sh ./sample.sh sample.json production _TOKEN

About

Register json to Shellscript variables

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages