gd_get: Download a file from Google Drive if needed

Description Usage Arguments Examples

View source: R/google_drive.R

Description

Download a file from Google Drive to the local project based on the information implied by the indicator file (including the location on google drive and the local destination location). Skips the download if the local file already exists and the remote and local hashes are identical.

Usage

1
2
3
gd_get(ind_file, type = NULL, overwrite = TRUE, verbose = FALSE,
  config_file = getOption("scipiper.gd_config_file"),
  ind_ext = getOption("scipiper.ind_ext"))

Arguments

ind_file

character name of the indicator file for which data should be downloaded. downloads the Google Drive object whose key equals the data_file basename

type

see type argument to googledrive::drive_download()

overwrite

see overwrite argument to googledrive::drive_download()

verbose

see verbose argument to googledrive::drive_download(); also used to determine whether to include messages specific to gd_get()

config_file

character name of the YAML file containing project-specific configuration information for Google Drive

ind_ext

the indicator file extension to expect at the end of ind_file

Examples

1
2
3
4
## Not run: 
gd_get('0_test/test_sheet.ind', type='xlsx', overwrite=TRUE)

## End(Not run)

USGS-R/scipiper documentation built on Aug. 14, 2018, 5:23 a.m.