Sha256: 175d9a17cc34d9b33a3757aaddef908d4710e8e07d94a65694422b10a2588428
Contents?: true
Size: 1.18 KB
Versions: 1
Compression:
Stored size: 1.18 KB
Contents
Redmine::Plugin.register :dummy_plugin do name 'Dummy Plugin' author '' author_url '' description '' version '2016' #into easy_settings goes available setting as a symbol key, default value as a value settings easy_settings: { } end Dir[File.dirname(__FILE__) + '/lib/dummy_plugin/easy_patch/**/*.rb'].each {|file| require_dependency file } # this block is executed once just after Redmine is started # means after all plugins are initialized # it is place for plain requires, not require_dependency # it should contain hooks, permissions - base class in Redmine is required thus is not reloaded ActiveSupport.on_load(:easyproject, yield: true) do require 'dummy_plugin/internals' require 'dummy_plugin/hooks' end # this block is called every time rails are reloading code # in development it means after each change in observed file # in production it means once just after server has started # in this block should be used require_dependency, but only if necessary. # better is to place a class in file named by rails naming convency and let it be loaded automatically # Here goes query registering, custom fields registering and so on ActionDispatch::Reloader.to_prepare do end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
redmine_extensions-0.1.15 | spec/redmine/plugins/dummy_plugin/init.rb |