data_backup: Backup select files for a state to archive drive

Description Usage Arguments See Also

View source: R/data.R

Description

Intended for saving databases that will be overwritten during data updates (e.g., standard, license, history). Note that this is potentially destructive to existing files in the archive drive (i.e., existing archived files will be overwritten), and you will need to specify overwrite = TRUE in this case.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
data_backup(
  state,
  files = c(file.path("E:/SA/Data-sensitive/Data-Dashboards", state,
    "standard.sqlite3"), file.path("E:/SA/Data-production/Data-Dashboards", state,
    "license.sqlite3"), file.path("E:/SA/Data-production/Data-Dashboards", state,
    "history.sqlite3")),
  archive_drive = "H:",
  overwrite = FALSE,
  ...
)

Arguments

state

2-letter abbreviation for state

files

vector of file paths that will be backed-up

archive_drive

drive to which the files will be copied

overwrite

If TRUE, existing files in the archive drive can be overwritten

...

additional arguments passed to file.copy

See Also

Other functions to manage data: data_archive(), data_destroy()


southwick-associates/lictemplate documentation built on Jan. 10, 2022, 6:44 p.m.