redmine_extensions 0.0.21 → 0.0.22

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 89feb8fc90a7076f29e1d07586a679bd78b7aa8c
4
- data.tar.gz: 1ea75d8d73b923099df2657887beba5fddc269a7
3
+ metadata.gz: f7ac333edb2cc8180083916b31b0427f4d21b24f
4
+ data.tar.gz: 9229dd36b4d816a8e3ee17429b4f66a6a0c9b12f
5
5
  SHA512:
6
- metadata.gz: 08c6c81dcc17b059cab7c77fcb8e41364a4466771534c808e71e453e3815c7809642360be901de2bcda31a7ce06d56d0dccd9aca8446cb5ced70cf3bc15d02d0
7
- data.tar.gz: 1b667d18f0133319e29c7ff0525b2cb1194c57732b46284bded5542dc1f45897b1fa72a2bc4581b05b99247c80cd23c1f27300e482db9f74f7a75bf39d6b04fc
6
+ metadata.gz: 5c46f1ee46fcaa2746e96fb2bc8cfb38f9fbb9d6f7596d41365bb2e192f49b81cf1c1f0c672f15a2ef4f9f7b13f5ab8fc4e810662e531234f84a576cda311885
7
+ data.tar.gz: e5c2521b4c39108aa090369cf1af674f59642e9a49d1f9cf411c173d798f45751a5f2cb26fbf9771720e81a427e3f6cf309a671bc1e8d0dc8d830856fb2232cc
@@ -68,6 +68,7 @@ module RedmineExtensions
68
68
  template 'hooks.rb.erb', "#{plugin_path}/lib/#{plugin_name_underscored}/#{model_name_underscored}_hooks.rb"
69
69
  template 'index.api.rsb.erb', "#{plugin_path}/app/views/#{model_name_pluralize_underscored}/index.api.rsb"
70
70
  template 'index.html.erb.erb', "#{plugin_path}/app/views/#{model_name_pluralize_underscored}/index.html.erb"
71
+
71
72
  if mail?
72
73
  template 'mailer.rb.erb', "#{plugin_path}/app/models/#{model_name_underscored}_mailer.rb"
73
74
  template 'mail_added.html.erb.erb', "#{plugin_path}/app/views/#{model_name_underscored}_mailer/#{model_name_underscored}_added.html.erb"
@@ -75,6 +76,7 @@ module RedmineExtensions
75
76
  template 'mail_updated.html.erb.erb', "#{plugin_path}/app/views/#{model_name_underscored}_mailer/#{model_name_underscored}_updated.html.erb"
76
77
  template 'mail_updated.text.erb.erb', "#{plugin_path}/app/views/#{model_name_underscored}_mailer/#{model_name_underscored}_updated.text.erb"
77
78
  end
79
+
78
80
  template 'migration.rb.erb', "#{plugin_path}/db/migrate/#{Time.now.strftime('%Y%m%d%H%M%S')}_create_#{@model_name_pluralize_underscored}.rb"
79
81
  template 'model.rb.erb', "#{plugin_path}/app/models/#{model_name_underscored}.rb"
80
82
  template 'new.html.erb.erb', "#{plugin_path}/app/views/#{model_name_pluralize_underscored}/new.html.erb"
@@ -1,6 +1,7 @@
1
1
  Description:
2
2
  The plugin generator creates stubs for a new Redmine plugin.
3
3
  Plugin is prepared for use in Redmine and Easy Redmine as well.
4
+ You can use --customer flag to generate a special plugin if you can make just a few changes to code. Backup this plugin before Redmine or Easy Redmine upgrade and move back for keep you changes.
4
5
 
5
6
  Example:
6
7
  rails g redmine_extensions:plugin NameOfNewPlugin
@@ -4,9 +4,12 @@ module RedmineExtensions
4
4
 
5
5
  attr_reader :plugin_path, :plugin_name_underscored, :plugin_pretty_name, :plugin_title
6
6
 
7
+ class_option :customer, type: :boolean, default: false, banner: '', :desc => 'plugin will act as customer modification. It is useful for changing few things and be uptodate with the core.'
8
+
7
9
  def initialize(*args)
8
10
  super
9
- @plugin_name_underscored = file_name.underscore
11
+
12
+ @plugin_name_underscored = options[:customer] ? "modification_#{file_name.underscore}" : file_name.underscore
10
13
  @plugin_pretty_name = plugin_name_underscored.titleize
11
14
  @plugin_path = "plugins/#{plugin_name_underscored}"
12
15
  @plugin_title = @plugin_name_underscored.camelize
@@ -54,4 +57,4 @@ module RedmineExtensions
54
57
  hook_for :entity, as: :entity, in: :redmine_extensions, type: :boolean
55
58
 
56
59
  end
57
- end
60
+ end
@@ -1,3 +1,3 @@
1
1
  module RedmineExtensions
2
- VERSION = '0.0.21'
2
+ VERSION = '0.0.22'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: redmine_extensions
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.21
4
+ version: 0.0.22
5
5
  platform: ruby
6
6
  authors:
7
7
  - Easy Software Ltd
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-02-22 00:00:00.000000000 Z
11
+ date: 2016-03-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails