Module: Patches

Defined in:
lib/patches.rb,
lib/patches/config.rb,
lib/patches/engine.rb,
lib/patches/version.rb,
lib/generators/patches.rb,
lib/patches/tenant_run_concern.rb,
lib/generators/patches/patch_generator.rb,
lib/patches/application_version_validation.rb

Defined Under Namespace

Modules: ApplicationVersionValidation, Generators, TenantRunConcern Classes: Base, Config, Engine, Notifier, Patch, Pending, Runner, TenantRunner, TenantWorker, Worker

Constant Summary collapse

MAJOR =
3
MINOR =
6
PATCH =
2
VERSION =
[MAJOR, MINOR, PATCH].compact.join(".").freeze

Class Method Summary collapse

Class Method Details

.class_name(path) ⇒ Object



8
9
10
11
# File 'lib/patches.rb', line 8

def self.class_name(path)
  match = path.match(/\d+_(.+?)\.rb/)
  match[1].camelcase if match
end

.default_pathObject



4
5
6
# File 'lib/patches.rb', line 4

def self.default_path
  Rails.root.join('db/patches/') if defined?(:Rails)
end

.loggerObject



13
14
15
# File 'lib/patches.rb', line 13

def self.logger
  @logger ||= Logger.new(STDOUT)
end

.logger=(log) ⇒ Object



17
18
19
# File 'lib/patches.rb', line 17

def self.logger=(log)
  @logger = log
end