caseywatts / gobl.js

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

GOBL CLI

GOBL Logo

Go Business Language - Command Line Interface

Released under the Apache 2.0 LICENSE, Copyright 2021,2022 Invopop Ltd..

Usage

This repo contains a gobl CLI tool which can be used to manipulate GOBL documents from the command line or shell scripts.

Build with:

go build ./cmd/gobl

Install with:

go install github.com/invopop/gobl.cli/cmd/gobl

gobl build

Build a complete GOBL document from one or more input sources. Example uses:

# Finalize a complete invoice
gobl build invoice.yaml

# Set the supplier from an external file
gobl build invoice.yaml \
    --set-file doc.supplier=supplier.yaml

# Set arbitrary values from the command line. Inputs are parsed as YAML.
gobl build invoice.yaml \
    --set doc.foo.bar="a long string" \
    --set doc.foo.baz=1234

# Set an explicit string value (to avoid interpetation as a boolean or number)
gobl build invoice.yaml \
    --set-string doc.foo.baz=1234 \
    --set-string doc.foo.quz=true

# Set the top-level object:
gobl build invoice.yaml \
    --set-file .=envelope.yaml

About

License:Apache License 2.0


Languages

Language:Go 96.2%Language:JavaScript 3.5%Language:Shell 0.1%Language:HTML 0.1%