Gemfile 2.77 KB
Newer Older
jplang's avatar
jplang committed
1
source 'https://rubygems.org'
2

3
gem "bundler", ">= 1.5.0"
4

maeda's avatar
maeda committed
5
gem "rails", "5.2.2"
maeda's avatar
maeda committed
6
gem "rouge", "~> 3.3.0"
7
gem "request_store", "1.0.5"
8
gem "mini_mime", "~> 1.0.1"
9
gem "actionpack-xml_parser"
10
gem "roadie-rails", "~> 1.3.0"
11
gem "mimemagic"
12
gem "mail", "~> 2.7.1"
13
gem "csv", "~> 3.0.1" if RUBY_VERSION >= "2.3" && RUBY_VERSION < "2.6"
14

15
gem "nokogiri", (RUBY_VERSION >= "2.3" ? "~> 1.10.0" : "~> 1.9.1")
16
gem "i18n", "~> 0.7.0"
17

18
# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
19
gem 'tzinfo-data', platforms: [:mingw, :x64_mingw, :mswin]
20
gem "rbpdf", "~> 1.19.6"
21 22 23

# Optional gem for LDAP authentication
group :ldap do
24
  gem "net-ldap", "~> 0.16.0"
25 26 27 28
end

# Optional gem for OpenID authentication
group :openid do
29
  gem "ruby-openid", "~> 2.3.0", :require => "openid"
jplang's avatar
jplang committed
30
  gem "rack-openid"
31 32
end

33
platforms :mri, :mingw, :x64_mingw do
34
  # Optional gem for exporting the gantt to a PNG file, not supported with jruby
35
  group :rmagick do
marutosijp's avatar
marutosijp committed
36
    gem "rmagick", ">= 2.14.0"
37
  end
38 39 40

  # Optional Markdown support, not for JRuby
  group :markdown do
41
    gem "redcarpet", "~> 3.4.0"
42
  end
43 44
end

45 46
# Include database gems for the adapters found in the database
# configuration file
47
require 'erb'
48
require 'yaml'
49 50
database_file = File.join(File.dirname(__FILE__), "config/database.yml")
if File.exist?(database_file)
51
  database_config = YAML::load(ERB.new(IO.read(database_file)).result)
52 53 54 55
  adapters = database_config.values.map {|c| c['adapter']}.compact.uniq
  if adapters.any?
    adapters.each do |adapter|
      case adapter
56
      when 'mysql2'
57
        gem "mysql2", "~> 0.5.0", :platforms => [:mri, :mingw, :x64_mingw]
58
      when /postgresql/
59
        gem "pg", "~> 1.1.4", :platforms => [:mri, :mingw, :x64_mingw]
60
      when /sqlite3/
61
        gem "sqlite3", "~>1.3.12", :platforms => [:mri, :mingw, :x64_mingw]
62
      when /sqlserver/
63
        gem "tiny_tds", "~> 1.0.5", :platforms => [:mri, :mingw, :x64_mingw]
64
        gem "activerecord-sqlserver-adapter", :platforms => [:mri, :mingw, :x64_mingw]
65
      else
jplang's avatar
jplang committed
66
        warn("Unknown database adapter `#{adapter}` found in config/database.yml, use Gemfile.local to load your own database gems")
67 68 69
      end
    end
  else
70
    warn("No adapter found in config/database.yml, please configure it first")
71
  end
72
else
73
  warn("Please configure your config/database.yml first")
74 75 76
end

group :development do
77
  gem "yard"
78 79 80
end

group :test do
81
  gem "rails-dom-testing"
82
  gem "mocha"
83
  gem "simplecov", "~> 0.14.1", :require => false
84
  # For running system tests
jplang's avatar
jplang committed
85
  gem 'puma', '~> 3.7'
86 87
  gem "capybara", '~> 2.13'
  gem "selenium-webdriver"
88 89
end

90 91
local_gemfile = File.join(File.dirname(__FILE__), "Gemfile.local")
if File.exists?(local_gemfile)
92
  eval_gemfile local_gemfile
jplang's avatar
jplang committed
93 94
end

95
# Load plugins' Gemfiles
96
Dir.glob File.expand_path("../plugins/*/{Gemfile,PluginGemfile}", __FILE__) do |file|
97
  eval_gemfile file
98
end