In Rdatatable/data.table@5e36615, I tried to put the .lintr config into a non-standard location and point to it in CI with the env approach mentioned in ?read_settings: R_LINTR_LINTER_FILE: .ci/.lintr. Also tried with .ci/.lintr.R (the exact file, not relying on auto-guessing the R extension).
However, this failed to get picked up, as seen by the 1000s of lints picked up in the associated job: https://github.com/Rdatatable/data.table/actions/runs/7523183440/job/20476211212?pr=5908
Am I doing something wrong?
I've also tried running options(lintr.linter_file = ".ci/.lintr") (and .ci/.lintr.R) to no avail. I've also print-debugged that file.exists(".ci/.lintr.R"), so the file is not in the wrong location / omitted for being in a hidden directory.
Currently, I'm needing to run lintr:::read_settings(".ci/lintr"); lint_package(parse_settings = FALSE) to accomplish what I intended. Really not pretty.
PS it might help for verbose=TRUE to report some info in read_settings() as well, e.g. which file was chosen, maybe even which settings are read as which values.
In Rdatatable/data.table@5e36615, I tried to put the
.lintrconfig into a non-standard location and point to it in CI with theenvapproach mentioned in?read_settings:R_LINTR_LINTER_FILE: .ci/.lintr. Also tried with.ci/.lintr.R(the exact file, not relying on auto-guessing the R extension).However, this failed to get picked up, as seen by the 1000s of lints picked up in the associated job: https://github.com/Rdatatable/data.table/actions/runs/7523183440/job/20476211212?pr=5908
Am I doing something wrong?
I've also tried running
options(lintr.linter_file = ".ci/.lintr")(and.ci/.lintr.R) to no avail. I've also print-debugged thatfile.exists(".ci/.lintr.R"), so the file is not in the wrong location / omitted for being in a hidden directory.Currently, I'm needing to run
lintr:::read_settings(".ci/lintr"); lint_package(parse_settings = FALSE)to accomplish what I intended. Really not pretty.PS it might help for
verbose=TRUEto report some info inread_settings()as well, e.g. which file was chosen, maybe even which settings are read as which values.