ecm_news 0.1.2.pre → 0.1.3.pre

Sign up to get free protection for your applications and to get access to all the features.
data/README.rdoc CHANGED
@@ -12,6 +12,10 @@ Add the gem to your bundle:
12
12
  Install your bundle:
13
13
 
14
14
  > bundle install
15
+
16
+ Generate initializer:
17
+
18
+ > rails generate ecm:news:install
15
19
 
16
20
  Add migrations:
17
21
 
@@ -16,4 +16,11 @@ de:
16
16
  messages:
17
17
  empty: Keine News gefunden.
18
18
  news: News
19
+ views:
20
+ pagination:
21
+ first: "« Erste Seite"
22
+ last: "Letzte Seite »"
23
+ previous: "‹ Zurück"
24
+ next: "Vor ›"
25
+ truncate: "..."
19
26
 
@@ -16,4 +16,11 @@ en:
16
16
  messages:
17
17
  empty: no news found.
18
18
  news: news
19
+ views:
20
+ pagination:
21
+ first: "« First"
22
+ last: "Last »"
23
+ previous: "‹ Prev"
24
+ next: "Next ›"
25
+ truncate: "..."
19
26
 
@@ -0,0 +1,16 @@
1
+ require 'active_support/core_ext/module/delegation'
2
+ require 'active_support/core_ext/module/attribute_accessors'
3
+ require 'active_support/hash_with_indifferent_access'
4
+
5
+ module Ecm
6
+ module News
7
+ module Configuration
8
+ def configure
9
+ yield self
10
+ end
11
+
12
+ # mattr_accessor :foo
13
+ # @@foo = nil
14
+ end
15
+ end
16
+ end
@@ -1,5 +1,5 @@
1
1
  module Ecm
2
2
  module News
3
- VERSION = "0.1.2.pre"
3
+ VERSION = "0.1.3.pre"
4
4
  end
5
5
  end
data/lib/ecm_news.rb CHANGED
@@ -5,9 +5,11 @@ require 'kaminari'
5
5
  require 'bootstrap-kaminari-views'
6
6
 
7
7
  require 'ecm/news/engine'
8
+ require 'ecm/news/configuration'
8
9
  require 'ecm/news/routing'
9
10
 
10
11
  module Ecm
11
12
  module News
13
+ extend Configuration
12
14
  end
13
15
  end
@@ -0,0 +1,15 @@
1
+ module Ecm
2
+ module News
3
+ module Generators
4
+ class InstallGenerator < Rails::Generators::Base
5
+ desc "Generates the intializer"
6
+
7
+ source_root File.expand_path('../templates', __FILE__)
8
+
9
+ def generate_intializer
10
+ copy_file "ecm_news.rb", "config/initializers/ecm_news.rb"
11
+ end
12
+ end
13
+ end
14
+ end
15
+ end
@@ -0,0 +1,2 @@
1
+ Ecm::News.configure do |config|
2
+ end
@@ -0,0 +1,18 @@
1
+ module Ecm
2
+ module News
3
+ module Generators
4
+ class LocalesGenerator < Rails::Generators::Base
5
+ desc "Copies the locale files to your application"
6
+
7
+ source_root File.expand_path('../../../../../../config/locales', __FILE__)
8
+
9
+ def generate_locales
10
+ copy_file "ecm.news.en.yml", "config/locales/ecm.news.en.yml"
11
+ copy_file "ecm.news.de.yml", "config/locales/ecm.news.de.yml"
12
+ copy_file "ecm.news.item.en.yml", "config/locales/ecm.news.item.en.yml"
13
+ copy_file "ecm.news.item.de.yml", "config/locales/ecm.news.item.de.yml"
14
+ end
15
+ end
16
+ end
17
+ end
18
+ end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ecm_news
3
3
  version: !ruby/object:Gem::Version
4
- hash: 961915972
4
+ hash: 961915968
5
5
  prerelease: 6
6
6
  segments:
7
7
  - 0
8
8
  - 1
9
- - 2
9
+ - 3
10
10
  - pre
11
- version: 0.1.2.pre
11
+ version: 0.1.3.pre
12
12
  platform: ruby
13
13
  authors:
14
14
  - Roberto Vasquez Angel
@@ -16,7 +16,7 @@ autorequire:
16
16
  bindir: bin
17
17
  cert_chain: []
18
18
 
19
- date: 2012-09-15 00:00:00 Z
19
+ date: 2012-09-18 00:00:00 Z
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency
22
22
  name: rails
@@ -313,18 +313,20 @@ files:
313
313
  - app/models/ecm/news.rb
314
314
  - app/models/ecm/news/item.rb
315
315
  - config/locales/ecm.news.item.de.yml
316
- - config/locales/pagination.de.yml
317
316
  - config/locales/ecm.news.item.en.yml
318
317
  - config/locales/ecm.news.de.yml
319
- - config/locales/pagination.en.yml
320
318
  - config/locales/ecm.news.en.yml
321
319
  - db/migrate/001_create_ecm_news_items.rb
322
320
  - lib/ecm_news.rb
321
+ - lib/generators/ecm/news/locales/locales_generator.rb
322
+ - lib/generators/ecm/news/install/install_generator.rb
323
+ - lib/generators/ecm/news/install/templates/ecm_news.rb
323
324
  - lib/tasks/ecm_news_tasks.rake
324
325
  - lib/ecm/news/active_admin/ecm_news_items.rb
325
326
  - lib/ecm/news/engine.rb
326
327
  - lib/ecm/news/version.rb
327
328
  - lib/ecm/news/routing.rb
329
+ - lib/ecm/news/configuration.rb
328
330
  - MIT-LICENSE
329
331
  - Rakefile
330
332
  - README.rdoc
@@ -1,8 +0,0 @@
1
- de:
2
- views:
3
- pagination:
4
- first: "&laquo; Erste Seite"
5
- last: "Letzte Seite &raquo;"
6
- previous: "&lsaquo; Zurück"
7
- next: "Vor &rsaquo;"
8
- truncate: "..."
@@ -1,8 +0,0 @@
1
- en:
2
- views:
3
- pagination:
4
- first: "&laquo; First"
5
- last: "Last &raquo;"
6
- previous: "&lsaquo; Prev"
7
- next: "Next &rsaquo;"
8
- truncate: "..."