Skip to content
Permalink
Browse files

Less text in warning, refer to help page

  • Loading branch information
lorenzwalthert committed Nov 30, 2019
1 parent 46fd77b commit 210c293b905b5e7be79a54bbab63cb5b7ef9ec87
Showing with 3 additions and 6 deletions.
  1. +3 −6 R/stylerignore.R
@@ -49,12 +49,9 @@ add_stylerignore <- function(pd_flat) {
pd_flat$indicator_off <- cumsum_start + cumsum_stop
is_invalid <- cumsum_start - cumsum_stop < 0 | cumsum_start - cumsum_stop > 1
if (any(is_invalid)) {
rlang::warn(c(
"Invalid stylerignore sequences found. The order in which the markers",
"must appear in code is `# styler: off`, always followed by",
"`# styler: on`. Multiple sequences are allowed but can't be nested,",
"the very last `# styler: on` can be omitted. stylerignore markers are",
"ignored after the first invalid marker."
warn(paste0(
"Invalid stylerignore sequences found, potentially ignoring some of the ",
"markers set.\nSee `help(\"stylerignore\", \"styler\")`."
))
}

0 comments on commit 210c293

Please sign in to comment.
You can’t perform that action at this time.