1.0.3 • Published 12 months ago

gettoml v1.0.3

Weekly downloads
-
License
MIT
Repository
-
Last release
12 months ago

toml-reader

this project serve to read toml files efficiently and use the result directly into a terminal.

Overview

  1. Run it
    1. By installing it
    2. Using npx
  2. Examples

Run it

By installing it

for installation : npm install -g gettoml or yarn global add gettoml

run gettoml --tomlPath path_to_toml.toml --valuePath path_to_value_in_toml

if in your shell scripts you need default values if no values were found in the toml file you can add --defaultValue defaultValue

Using npx

skip the installation part, and add npx before gettoml as follows: npx gettoml ...

Examples

if you have a toml file named example.toml as below:

lang = "typescript"

[build]
command = "yarn build"

you can find :

  • the lang using the command npx gettoml --tomlPath example.toml --valuePath lang
  • the build command using the command npx gettoml --tomlPath example.toml --valuePath build.command
  • a hypothetical value named push using the command npx gettoml --tomlPath example.toml --valuePath push --defaultValue "yarn deploy"
1.0.3

12 months ago

1.0.2

12 months ago

1.0.1

12 months ago

1.0.0

12 months ago