Project

General

Profile

Actions

Patch #44598

open

Remove remaining JRuby-specific code and comments

Added by Go MAEDA about 12 hours ago.

Status:
New
Priority:
Normal
Assignee:
-
Category:
Code cleanup/refactoring

Description

Redmine no longer supports JRuby, and most of the code related to JRuby was removed in Redmine 4.1.0 (#29441). However, some code, test conditions, and comments that were written for JRuby still remain in the source. For example, config/configuration.yml.example still contains a note about "Windows + JRuby 1.6.2".

I would like to propose removing them. The attached patch removes the following:

  • Code
    • Redmine::Platform.mswin?: the check for RUBY_PLATFORM 'java'
    • Redmine::Utils::Shell.shell_quote_command: the branch for JRuby on Windows that returns the command without quoting
    • Redmine::Scm::Adapters::AbstractAdapter#parse_xml: the workaround that removes the XML declaration on JRuby
    • extra/svn/reposman.rb: the check for RUBY_PLATFORM 'java' in mswin?
    • lib/tasks/ci.rake: the selection of the jdbcsqlite3 adapter
  • Tests
    • test/test_helper.rb: the replacement of backslashes in repository_path, which was needed only for JRuby on Windows
    • test/unit/lib/redmine/scm/adapters/git_adapter_test.rb: the JRUBY_SKIP and JRUBY_SKIP_STR constants, the six branches that skip tests on JRuby, and the comment that explains why they were skipped
    • test/unit/repository_bazaar_test.rb: the JRuby condition in RUN_LATIN1_OUTPUT_TEST
    • test/unit/lib/redmine/export/pdf_test.rb: the selection of the "SJIS" encoding on JRuby
  • Comments
    • config/configuration.yml.example: the note about paths that contain spaces on "Windows + JRuby 1.6.2". In addition, "On Windows + CRuby" is changed to "On Windows", because the distinction is no longer necessary.

The patch does not change the behavior on CRuby, because all the removed code was executed only on JRuby.


Files


Related issues

Related to Redmine - Patch #29441: Remove code related to JRuby and unsupported Ruby versionsClosedJean-Philippe LangActions
Actions #1

Updated by Go MAEDA about 12 hours ago

  • Related to Patch #29441: Remove code related to JRuby and unsupported Ruby versions added
Actions

Also available in: Atom PDF