Skip to content

Commit

Permalink
Apply # nolint; NOTE: library(lintr) has many options. For example, t…
Browse files Browse the repository at this point in the history
…o nolint a block of code: # nolint start and # nolint end can be used; (done in this commit)

Also note, possible to turn off  SPECIFIC linters (also done in this commit for "object_name_linter")
  • Loading branch information
jimrothstein committed Sep 30, 2024
1 parent ff67700 commit 0076b24
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
4 changes: 3 additions & 1 deletion data-raw/create_admiral_adlb.R
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,10 @@
#

# Preliminary
library(diffdf)
library(diffdf) # nolint

# To clarify directories (can be removed)
# nolint start: object_name_linter
CACHE_DIR <- "~/.cache/R/admiral_templates_data/"
DATA_DIR <- "data-dir"
DATA_RAW <- "data-raw"
Expand All @@ -15,6 +16,7 @@ TEMPLATE_DIR <- "inst/templates/"
THE_FILE <- paste0(CACHE_DIR, "/adlb.rda")
THE_FILE <- paste0(CACHE_DIR, "/adsl.rda")
if (file.exists(THE_FILE)) file.remove(THE_FILE)
# nolint end

#
# STEPS
Expand Down
4 changes: 3 additions & 1 deletion data-raw/create_admiral_adsl.R
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,10 @@
#

# Preliminary
library(diffdf)
library(diffdf) # nolint


# nolint start: object_name_linter.
# To clarify directories (can be removed)
CACHE_DIR <- "~/.cache/R/admiral_templates_data/"
DATA_DIR <- "data-dir"
Expand All @@ -16,6 +17,7 @@ TEMPLATE_DIR <- "inst/templates/"
THE_FILE <- paste0(CACHE_DIR, "/adlb.rda")
THE_FILE <- paste0(CACHE_DIR, "/adsl.rda")
if (file.exists(THE_FILE)) file.remove(THE_FILE)
# nolint end

#
# STEPS
Expand Down

0 comments on commit 0076b24

Please sign in to comment.