Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
if (requireNamespace(c("callr", "git2r"), quietly = TRUE)) {
has_git = git2r::in_repository()
if (has_git) {
message("Running `git2r::pull()` in the background.")
callr::r_bg(function() {git2r::pull()})$wait()$get_result()
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment