json-key-remover

0.1.4 • Public • Published

Json key remover cli

Remove/add/replace keys json cli. Utilite configured via package.json and cli.

Install

npm install json-key-remover -g

Usages

Help: json-key-remover --help

Example CLI: json-key-remover --target <PATH TO TARGET FILE> --destination <PATH TO DESTINATION FILE> --add "key1=2,key2=hello,key3/sub-key3-1=message" --remove "key4,key5,key6/subkey"

Example CLI: json-key-remover --config <PATH TO CONFIG FILE>"

Example config file

config.json:

{
    "target": "target.json",
    "destination": "destination.json",
    "remove": [
        "key1",
        "key2",
        "key3/sub-key3-1",
        "key3/sub-key3-2",
        "remover"
    ],
    "add": {
        "key1": "key1-val",
        "key3/sub-key3-3": "sub-key3-3-val"
    }
}

Readme

Keywords

Package Sidebar

Install

npm i json-key-remover

Weekly Downloads

2

Version

0.1.4

License

ISC

Unpacked Size

9.05 kB

Total Files

6

Last publish

Collaborators

  • samuray