Skip to content

Instantly share code, notes, and snippets.

@dragosmg
Forked from romainfrancois/rprofile.R
Created March 19, 2020 14:23
Show Gist options
  • Select an option

  • Save dragosmg/363794742821fec8d40f0e660924029f to your computer and use it in GitHub Desktop.

Select an option

Save dragosmg/363794742821fec8d40f0e660924029f to your computer and use it in GitHub Desktop.
if(interactive()) {
.__Rprofile_env__. <- new.env(parent = emptyenv())
.__Rprofile_env__.[["install"]] <- pak::pkg_install
attach(.__Rprofile_env__.)
library(usethis, warn.conflicts = FALSE)
library(conflicted)
conflict_prefer("filter", "dplyr")
conflict_prefer("sql", "dbplyr")
library(usethis)
library(reprex)
library(prompt)
set_prompt(function(...){
paste0(
"[", git_branch(), git_dirty(), git_arrows(), "] ",
prompt_memuse()
)
})
options(
warnPartialMatchAttr = TRUE,
warnPartialMatchDollar = TRUE,
warnPartialMatchArgs = TRUE,
error = rlang::entrace,
keep.source = TRUE,
keep.source.pkgs = TRUE
)
utils::rc.settings(ipck = TRUE)
options("devtools.desc" = list(
Author = "Romain François",
License = "MIT + file LICENSE",
Version = "0.0.0.9000"
))
options("devtools.name" = "Romain François")
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment