...and use the latest (2020) Travis build environment: focal
2.6 is the earliest currently supported Ruby version:
https://www.ruby-lang.org/en/downloads/branches/
The focal environment doesn't seem to support openjdk 8. Here's the
failure from the build:
install-jdk.sh 2020-06-02
Expected feature release number in range of 9 to 17, but got: 8
The command "~/bin/install-jdk.sh --target "/home/travis/openjdk8" --workspace "/home/travis/.cache/install-jdk" --feature "8" --license "GPL" --cacerts" failed and exited with 3 during .
It looks like JRuby 9.1 isn't under development: the last release was in
2018, and it's described as being "compatible with Ruby 2.3.x", which is
a very old version . It feels OK to drop it.
JRuby 9.2 says it's "compatible with Ruby 2.5.x", but it's the latest
JRuby version so it seems like something we should keep.
The fewer exceptions to the default the better, and we're going to want
to use an access modifier in a generator, which will end up in other
people's codebases, so we should be as conventional as possible.
There doesn't seem to be any particular reason to exclude these. It's at
least nice to have consistent use of quotes within the same file.
This does run the risk of imposing our specific rubocop rules on other
people's code (double vs single quotes is the cause of holy wars), but
if anything obviously awful comes up, we can exclude generators from
that specific rule.
We do however need to exclude the templates, since these have a .rb
extension despite containing erb tags.
Now that we don't need to support Ruby 2.1 or 2.2, we can use the latest
version of Rubocop (which dropped support for those versions).
Also remove things from Rubocop which are now defaults:
- FrozenStringLiteralComment is now on by default
- DisplayCopNames used to be off by default but now seems to be on
- This project doesn't seem to have ever had gemfiles or vendor
directories - my guess is that this was a copy-paste from another
project.
There are no violations of these and there doesn't seem to be any
particular reason to disable these rules.
One reason to have as few exceptions as possible is that it insulates us
from future changes to cop names and attributes.
This is enabled by default in later versions of Rubocop. Making this
change now removes this conflict for people running later versions.
Automatically fixed with `rubocop -a`
This has no violations and there doesn't seem to be a good reason to
disable it.
Also it had two declarations - these were both added in the initial
commit which added Rubocop - presumably due to the config being copied
from a previous project (?).
* CI against Ruby 2.2.8/2.3.5/2.4.2
* Remove unnecessary magic comments with ruby 2.0 or later
* Change `TargetRubyVersion` to 2.0
ruby 1.9.3 has already been dropped by 0569b065d7
* Change `TargetRubyVersion` to 2.1
* Drop jruby1.7 on Travis