Add, commit, and reset tables in a dolt database

dolt_add(tables = NULL, conn = dolt(), collect = NULL, show_sql = NULL)

dolt_commit(
  all = TRUE,
  message = NULL,
  author = NULL,
  date = NULL,
  allow_empty = FALSE,
  conn = dolt(),
  collect = NULL,
  show_sql = NULL
)

dolt_reset(
  hard = FALSE,
  tables = NULL,
  conn = dolt(),
  collect = NULL,
  show_sql = NULL
)

Arguments

tables

Which tables to be reset? Defaults to all tables if NULL.

conn

the database connection

collect

whether to collect the result into R or return a dbplyr::tbl_lazy() to be further processed before collecting. Defaults to TRUE, can be set with the environment variable DOLT_COLLECT.

show_sql

Whether to print the SQL statements used internally to fetch the data. Useful for learning how Dolt works internally. Defaults to FALSE, can be set with the environment variable DOLT_VERBOSE.

all

stage all tables before committing?

message

A commit message. If NULL in an interactive session, the user will be prompted. Otherwise will error if empty.

author, date

Author and date. If null, uses the ones set in dolt-config. Author should be in the format "A U Thor author@example.com"

allow_empty

Allow recording a commit that has the exact same data as its sole parent. This is usually a mistake, so it is FALSE by default.

hard

Reset working and staged tables? If FALSE (default), a "soft" reset will be performed, only unstaging staged tables. If TRUE, all working and staged changes will be discarded.