New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

json-edit-cli

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

json-edit-cli

Quickly manipulate JSON file values from the command line

latest
Source
npmnpm
Version
0.1.1
Version published
Maintainers
1
Created
Source

edit-json

Quickly manipulate JSON file values from the command line

oclif Version Codecov Travis CI License

Usage

$ npm install -g json-edit-cli
$ json COMMAND
running command...
$ json (-v|--version|version)
json-edit-cli/0.1.1 win32-x64 node-v10.15.3
$ json --help [COMMAND]
USAGE
  $ json COMMAND
...

Commands

json copy [FILE]

describe the command here

USAGE
  $ json copy [FILE]

OPTIONS
  -f, --force
  -h, --help       show CLI help
  -n, --name=name  name to print

See code: src\commands\copy.ts

json del [FILE]

describe the command here

USAGE
  $ json del [FILE]

OPTIONS
  -V, --verbose  Enable verbose output:
                 - Prints full JSON structure, with edits made.

  -h, --help     show CLI help

  -k, --key=key  (required) Designate the property accessor/key path string. May access nested properties by using
                 dot-notation. For example,
                 --key="property.nested-property" will allow access to the "nested-property" field of "property"

  -y, --yes      Skip confirmation and remove the property from the JSON structure

See code: src\commands\del.ts

json get PATH [ACCESSOR]

Inspect a full JSON file, or specific property within.

USAGE
  $ json get PATH [ACCESSOR]

ARGUMENTS
  PATH      An absolute or relative path pointing to a JSON file

  ACCESSOR  Property to retrieve from the file. May use dot-notation to reference nested values. If omitted, the full
            JSON object is printed.

OPTIONS
  -h, --help  show CLI help
  --no-color  Control use of colors. Defaults to true

See code: src\commands\get.ts

json help [COMMAND]

display help for json

USAGE
  $ json help [COMMAND]

ARGUMENTS
  COMMAND  command to show help for

OPTIONS
  --all  see all commands in CLI

See code: @oclif/plugin-help

json set [FILE]

DESCRIPTION

USAGE
  $ json set [FILE]

OPTIONS
  -V, --verbose      Enable verbose output:
                     - Prints full JSON structure, with edits made.

  -h, --help         show CLI help

  -k, --key=key      (required) Designate the property accessor/key path string. May access nested properties by using
                     dot-notation. For example,
                     --key="property.nested-property" will allow access to the "nested-property" field within the
                     object at "property"

  -v, --value=value  (required) Designate the new value. Values will be de-serialized with JSON.parse; For example,
                     --value "{ \"key\": \"value\" }"

DESCRIPTION
  Set the value for a new or existing property key in a JSON file.

See code: src\commands\set.ts

Keywords

oclif

FAQs

Package last updated on 29 Aug 2019

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts