summaryrefslogtreecommitdiff
path: root/config/initializers
diff options
context:
space:
mode:
authorStefan Morgenthaler <gh@guerilladesigns.com>2012-07-10 16:12:19 +0200
committerStefan Morgenthaler <gh@guerilladesigns.com>2012-07-10 16:12:19 +0200
commit4dae41d5dc90473e3c5c08064c25433fecf5abd3 (patch)
treeb5ffb5f946f819cfe298b1992d7a4b6a6e8cba29 /config/initializers
parent12b34c8115bbb35524880bca4f21ad0939de4b77 (diff)
downloadgitlab-ce-4dae41d5dc90473e3c5c08064c25433fecf5abd3.tar.gz
Changes done as per feedback
Diffstat (limited to 'config/initializers')
-rw-r--r--config/initializers/1_settings.rb10
1 files changed, 10 insertions, 0 deletions
diff --git a/config/initializers/1_settings.rb b/config/initializers/1_settings.rb
index 8b9ed8aebd6..bbf5976bf74 100644
--- a/config/initializers/1_settings.rb
+++ b/config/initializers/1_settings.rb
@@ -101,5 +101,15 @@ class Settings < Settingslogic
def default_projects_limit
app['default_projects_limit'] || 10
end
+
+ def backup_path
+ t = app['backup_path'] || "backups/"
+ t = /^\//.match(t) ? t : File.join(Rails.root + t)
+ t
+ end
+
+ def backup_keep_time
+ app['backup_keep_time'] || 0
+ end
end
end