Learn R Programming

tzupdater (version 0.1.5)

install_last_tz: install_last_tz

Description

Install latest tz database if required, and make it active.

Will stop in case it is not possible to know what the last version is.
If it happens browse IANA website at https://www.iana.org/time-zones and install last version with install_tz(version).
?install_tz for details.

Usage

install_last_tz(
  zic_path = NA,
  target_folder = paste0(tempdir(), "/tzupdater/data/IANA_release"),
  verbose = TRUE
)

Value

None.

Arguments

zic_path

Optional for Windows: path to the zic compiler (if not in C:\Cygwin\usr\sbin).

target_folder

Optional target folder. Default will be tzupdater/data/IANA_release as subdirectory of your temp dir.

verbose

Print information to the console TRUE/FALSE. Default TRUE.

Examples

Run this code

# Get the latest version available and compile. 
# If your tz database is already the latest, do nothing.
install_last_tz()

# Same, but more verbose.
install_last_tz(verbose = TRUE)

# On Windows: install latest tz database, with Cygwin installed in c:\Cygwin.
install_last_tz(zic_path="C:\\Cygwin\\usr\\sbin")

Run the code above in your browser using DataLab