gitlab-org--gitlab-foss/lib/gitlab.rb

24 lines
520 B
Ruby
Raw Normal View History

require_dependency 'gitlab/git'
2015-07-15 13:59:38 +00:00
module Gitlab
COM_URL = 'https://gitlab.com'.freeze
APP_DIRS_PATTERN = %r{^/?(app|config|ee|lib|spec|\(\w*\))}
def self.com?
# Check `staging?` as well to keep parity with gitlab.com
Gitlab.config.gitlab.url == COM_URL || staging?
end
def self.staging?
Gitlab.config.gitlab.url == 'https://staging.gitlab.com'
end
def self.dev?
Gitlab.config.gitlab.url == 'https://dev.gitlab.org'
end
def self.inc_controlled?
dev? || staging? || com?
end
2015-07-15 13:59:38 +00:00
end