wrgl commit

Commit a CSV file under a branch

wrgl commit {BRANCH | --all} [CSV_FILE_PATH] COMMIT_MESSAGE [-p PRIMARY_KEY] [flags]

Flags

--all

commit all branches that have branch.file configured.

-h, --help

help for commit

--mem-limit

limit memory consumption (in bytes). If not set then memory limit is automatically calculated.

-n, --num-workers

number of CPU threads to utilize

-p, --primary-key

field names to be used as primary key for table

--set-file

set branch.file to CSV_FILE_PATH. If branch.file is set then you don't need to specify CSV_FILE_PATH in subsequent commits to BRANCH.

--set-primary-key

set branch.primaryKey to PRIMARY_KEY. If branch.primaryKey is set then you don't need to specify PRIMARY_KEY in subsequent commits to BRANCH.

Inherited flags

--badger-log

set Badger log level, valid options are "error", "warning", "debug", and "info" (defaults to "error")

--cpuprofile

write cpu profile to file

--debug-file

output debug logs to a file

--heapprofile

write heap profile to file

--wrgl-dir

parent directory of repo, default to current working directory.

Examples

# commit using primary key id
wrgl commit main data.csv "initial commit" -p id

# commit using composite primary key
wrgl commit main data.csv "new data" -p id,date

# commit from stdin
cat data.csv | wrgl commit main - "my commit" -p id

# commit while setting branch.file and branch.primaryKey
wrgl commit main data.csv "my commit" -p id --set-file --set-primary-key

# commit without having to specify CSV_FILE_PATH and PRIMARY_KEY (read from branch.file and branch.primaryKey)
wrgl commit main "easy commit"

# commit all branches that have branch.file configured
wrgl commit --all "mass commit"