We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
exclude:
.lintr
When using the 3.0.0 CRAN release of lintr, listing with the following .lintr file results in an unexpected error:
linters: linters_with_defaults( line_length_linter(100) ) exclude: list( "bad.R" = list( 1, # global exclusions are unnamed line_length_linter = 4:6 ) )
(adapted from the Get Started page)
Error message when running lint_dir():
lint_dir()
$ Rscript -e 'lintr::lint_dir(".")' Error in `[.data.frame`(rex::re_matches(lines, exclude, locations = TRUE), : undefined columns selected Calls: <Anonymous> ... do.call -> <Anonymous> -> lapply -> FUN -> [ -> [.data.frame Execution halted
To reproduce: run Rscript -e 'lintr::lint_dir(".")' from a directory containing the .lintr file above, and the following bad.R:
Rscript -e 'lintr::lint_dir(".")'
bad.R
tmp = "value" # regular comment # really long comment ............................................................................................................ # really long comment ............................................................................................................ # really long comment ............................................................................................................ # regular comment
The text was updated successfully, but these errors were encountered:
Hi @jabenninghoff. You're looking for exclusions: list(...). exclude: ... modifies the regex used for the in-file exclusion syntax.
exclusions: list(...)
exclude: ...
Sorry, something went wrong.
Sorry for the premature closure - thanks for reporting this bug in the documentation!
exclusions
Successfully merging a pull request may close this issue.
When using the 3.0.0 CRAN release of lintr, listing with the following
.lintr
file results in an unexpected error:(adapted from the Get Started page)
Error message when running
lint_dir()
:To reproduce: run
Rscript -e 'lintr::lint_dir(".")'
from a directory containing the.lintr
file above, and the followingbad.R
:The text was updated successfully, but these errors were encountered: