Changelog
0.3.0
Breaking changes
Jarl now excludes by default file paths matching the following patterns:
.git/,renv/,revdep/,cpp11.R,RcppExports.R,extendr-wrappers.R, andimport-standalone-*.R.A new CLI argument
--no-default-excludecan be used to check those files as well. This argument overrides thedefault-exclude = trueoption when set injarl.toml(#178, @novica).
Features
--output-format jsonnow contains two fieldsdiagnosticsanderrors(#219).- Better support for namespaced function calls, both when reporting violations and when fixing them (#221).
- The
class_equalsrule now also reports cases likeidentical(class(x), "foo")andidentical("foo", class(x))(#234). - New rules:
expect_s3_class(#235)expect_type(#226)fixed_regex(#227)sprintf(#224)string_boundary(#225)vector_logic(#238)
Fixes
# nolintcomments are now properly applied to nodes that are function arguments, e.g.foo( # nolint any(is.na(x)) )does not report a violation anymore (#229).
Other changes
expect_namedno longer reports cases likeexpect_equal(x, names(y))because rewriting those asexpect_named(y, x)would potentially change the intent of the test and the way it is read (#220).
0.2.1
Other
- Important performance improvement when using
--fix, in particular in projects with many R files (#217).
0.2.0
Breaking changes
- For consistency between CLI arguments and
jarl.tomlarguments, the following CLI arguments are renamed (#199):--select-rulesbecomes--select--ignore-rulesbecomes--ignore--assignment-opbecomes--assignment
Features
- New argument
extend-selectinjarl.tomland--extend-selectin the CLI to select additional rules on top of the existing selection. This can be useful to select opt-in rules in addition to the default set of rules (#193). - Added support for
seqandseq2rules (#187). - Added support for several rules related to
testthat. Those rules are disabled by default and can be enabled by combiningselectorextend-selectwith the rule name or theTESTTHATgroup rule name. Those rules are:expect_length(#211)expect_named(#212)expect_not(#204)expect_null(#202)expect_true_false(#191)
Fixes
implicit_assignmentno longer reports cases insidequote()(#209).
Documentation
- Added section on Neovim to the Editors page (#188, @bjyberg).
- Added page “Tutorial: add a new rule” (#183).
0.1.2
Features
- Added support for
list2dfrule (#179). - Added support for
browserrule (#185, @jonocarroll). - Added support for
system_filerule (#186).
Fixes
- (Hopefully) Fixed wrong printing of ANSI characters in multiple terminals on Windows (#179, thanks @novica for the report).
Documentation
- Added sections on RStudio and Helix to the Editors page.
- Added installation instructions using Scoop on Windows.
0.1.1
Fixes
- Fix discovery of
jarl.tomlby the Jarl extension (#175, thanks @DavisVaughan for the report). - Rule
duplicated_argumentno longer reportscli_functions where multiple arguments have the same name (#176, thanks @DavisVaughan for the report).
Documentation
- The docs of
assignmentrule now explain how to change the preferred assignment operator.
0.1.0
First release (announced)