-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #29 from davidruvolo51/fix/cran-tests
rheroicons v0.4.0
- Loading branch information
Showing
20 changed files
with
6,235 additions
and
4,092 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,72 @@ | ||
#' //////////////////////////////////////////////////////////////////////////// | ||
#' FILE: .Rprofile | ||
#' AUTHOR: David Ruvolo | ||
#' CREATED: 2021-07-29 | ||
#' MODIFIED: 2021-07-29 | ||
#' PURPOSE: workspace configurations and useful functions for vscode+R env | ||
#' STATUS: working; ongoing | ||
#' PACKAGES: NA | ||
#' COMMENTS: https://github.com/davidruvolo51/rprofile | ||
#' //////////////////////////////////////////////////////////////////////////// | ||
|
||
# set options | ||
options( | ||
|
||
# options: shiny | ||
shiny.port = 8000, | ||
shiny.launch.browser = FALSE, | ||
|
||
# options: radian | ||
radian.insert_new_line = FALSE, | ||
radian.prompt = "\033[0;34m>\033[0m ", | ||
|
||
# options: vscode R | ||
vsc.use_httpgd = TRUE, | ||
vsc.helpPanel = "Beside", | ||
vsc.viewer = "Beside", | ||
vsc.browser = "Beside", | ||
vsc.show_object_size = FALSE, | ||
|
||
# options: languageserver | ||
languageserver.formatting_style = function(options) { | ||
styler::tidyverse_style( | ||
start_comments_with_one_space = TRUE, | ||
indent_by = 4 | ||
) | ||
} | ||
) | ||
|
||
|
||
#' @title Clear | ||
#' @name clear | ||
#' @description clear the active terminal | ||
#' @noRD | ||
clear <- function() { | ||
cmds <- list("unix" = "clear", "windows" = "cls") | ||
system(cmds[[.Platform$OS.type]]) | ||
} | ||
|
||
|
||
#' @title Quietly Load Package | ||
#' @name library2 | ||
#' @description suppress messages when loading a package | ||
#' @param pkg the name of the package | ||
#' @noRd | ||
library2 <- function(pkg) { | ||
suppressPackageStartupMessages(library(pkg, character.only = TRUE)) | ||
} | ||
|
||
|
||
#' @title Remove2 | ||
#' @name rm2 | ||
#' @description Force remove all objects from the current environment | ||
#' @param except optional an array of object names to ignore | ||
#' @noRd | ||
rm2 <- function(except = NULL) { | ||
ignore <- c("clear", "library2", "rm2") | ||
if (!is.null(except)) ignore <- c(ignore, except) | ||
rm(list = setdiff(ls(envir = .GlobalEnv), ignore), envir = .GlobalEnv) | ||
} | ||
|
||
# start renv: make sure this is always last! | ||
source("renv/activate.R") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
linters: with_defaults(line_length_linter = line_length_linter(87), commented_code_linter = NULL, object_usage_linter=NULL, object_name_linter=NULL) | ||
exclusions: list("renv/") | ||
exclude_start: "# nolint start" | ||
exclude_end: "# nolint end" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.