From 22d4e32ca4d7f6ffecd171f7396eeeecb044740a Mon Sep 17 00:00:00 2001 From: chiu Date: Wed, 21 Aug 2019 11:09:29 +0800 Subject: [PATCH] Update personal_journal.gemspec --- personal_journal.gemspec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/personal_journal.gemspec b/personal_journal.gemspec index c881ac0..0658db3 100644 --- a/personal_journal.gemspec +++ b/personal_journal.gemspec @@ -2,7 +2,7 @@ $:.push File.expand_path("../lib", __FILE__) # Maintain your gem's version: require "personal_journal/version" -rails_root = `pwd`.gsub("\n", "") +rails_root = ENV['RAILS_ENV'] || 'production' app_path = File.expand_path(File.dirname(__FILE__) + '/..') puts rails_root d = Dir.entries('/').select {|entry| File.directory? File.join('/',entry) and !(entry =='.' || entry == '..') }