Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Timmmm/json2cbor

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

JSON2CBOR

This repo contains two really simple programs to convert JSON to CBOR and vice versa. It does the transformation using serde-transcode.

Install

  1. Install Rust.
  2. cargo install json2cbor.

Use

json2cbor and cbor2json both take the same flags & arguments

Reads/writes to stdin/stdout by default

echo '{"foo":"bar"}' | json2cbor | cbor2json
# Output: {"foo":"bar"}

Read from an input file

json2cbor in.json

Write to an output file

echo '{"foo":"bar"}' | json2cbor -o out.cbor

Read & write to files

json2cbor -o out.cbor in.json

Get help

json2cbor --help

About

Convert JSON to CBOR

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages