Project

General

Profile

Actions

Patch #39547

closed

Prevent automatic requiring of unnecessary gems at runtime

Added by Go MAEDA about 1 year ago. Updated 10 months ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
Gems support
Target version:
Start date:
Due date:
% Done:

0%

Estimated time:

Description

We can set `require: false` to the yard gem in Gemfile. This will slightly reduce the memory used by Redmine.

The yard gem is only needed when executing `rake yard` and is not necessary when running the Redmine application. Moreover, since `require 'yard'` is executed internally when running `rake yard`, there is no need to load 'yard' when starting up Redmine.

diff --git a/Gemfile b/Gemfile
index 5b789f927..11e6acdf8 100644
--- a/Gemfile
+++ b/Gemfile
@@ -89,7 +89,7 @@ end

 group :development do
   gem 'listen', '~> 3.3'
-  gem "yard" 
+  gem 'yard', require: false
 end

 group :test do
Actions

Also available in: Atom PDF