Skip to content
New issue

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

Typo in description of available linters #410

Closed
even4void opened this issue Sep 22, 2019 · 3 comments

Comments

@even4void
Copy link

commented Sep 22, 2019

I believe absolute_path_linter should read absolute_paths_linter (missing s) in the README.

@russHyde

This comment has been minimized.

Copy link
Collaborator

commented Sep 23, 2019

Hi. If you look in the source code for path_linters.R https://github.com/jimhester/lintr/blob/master/R/path_linters.R the linter is currently called absolute_path_linter.

There is an absolute_paths_linter, in the file deprecated.R, but I think it's eventually going to be removed. Apologies for any confusion, but I think the README is up to date with the package with respect to these linters.

@russHyde russHyde closed this Sep 23, 2019
@even4void

This comment has been minimized.

Copy link
Author

commented Sep 23, 2019

I raised this issue because I could not configure with_defaults for flycheck in Emacs using the instructions in the README. By looking around a little bit in R, I found that default_linters include absolute_paths_linter indeed (you can check by yourself with str(lintr::default_linters) at the R prompt). At least, this solved my issue with Emacs. Maybe my version of lintr is too old then (v 1.0.3, packaged by Jim on 2018-11-08 16:39:01 UTC).

@russHyde

This comment has been minimized.

Copy link
Collaborator

commented Sep 23, 2019

No problem. The released version of lintr is lagging behind the github version quite a bit. For the current github version, the default linters are as follows:

> sort(names(default_linters))
 [1] "assignment_linter"                "closed_curly_linter"             
 [3] "commas_linter"                    "commented_code_linter"           
 [5] "cyclocomp_linter"                 "equals_na_linter"                
 [7] "function_left_parentheses_linter" "infix_spaces_linter"             
 [9] "line_length_linter"               "no_tab_linter"                   
[11] "object_length_linter"             "object_name_linter"              
[13] "object_usage_linter"              "open_curly_linter"               
[15] "pipe_continuation_linter"         "single_quotes_linter"            
[17] "spaces_inside_linter"             "spaces_left_parentheses_linter"  
[19] "trailing_blank_lines_linter"      "trailing_whitespace_linter"

So there doesn't appear to be a file-path linter within this set (although you are right, the absolute_paths_linter is present in the defaults for the CRAN version).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.