publish 0.3.0 → 0.4.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +6 -14
- data/.travis.yml +0 -1
- data/CHANGELOG.md +5 -1
- data/Gemfile +3 -2
- data/README.md +1 -1
- data/lib/mongoid/publish/version.rb +1 -1
- data/publish.gemspec +12 -14
- data/test/dummy/config/application.rb +5 -22
- data/test/dummy/config/boot.rb +4 -9
- data/test/dummy/config/environment.rb +2 -2
- data/test/dummy/config/environments/development.rb +10 -13
- data/test/dummy/config/environments/test.rb +14 -12
- data/test/dummy/config/initializers/session_store.rb +1 -6
- data/test/dummy/config/mongoid.yml +23 -15
- data/test/dummy/config/routes.rb +2 -2
- metadata +19 -21
- data/gemfiles/mongoid-master.gemfile +0 -10
- data/test/dummy/app/helpers/posts_helper.rb +0 -2
checksums.yaml
CHANGED
@@ -1,15 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
metadata.gz: !binary |-
|
9
|
-
YTJkNTgyM2E5MTNjNGNlZGIyMzUzZmNhMjYwNWZhNzUzODY2ZDkwOGE4ZGEw
|
10
|
-
ZGZlZGJiZDI3NTcyNjg1Y2Q5MzRjMzg5Yjk2Y2M4OWE1YWIzYThlZDJlZGZl
|
11
|
-
NzZiYTcyNmRjMjhkZTBkZmRjMzUwZThiMjllMDJjZDIzMDFmMmY=
|
12
|
-
data.tar.gz: !binary |-
|
13
|
-
OTQ0Njk3ZDFmZDhmMTM4NjhhNzBkNjI4MTUzN2U2MjM2Njc3ZDEwN2RkMzc3
|
14
|
-
NmJjNGJlMGRmOWE1ODYyMWQwNGVhYTdiNzNjZTExODE3ODYyYzA3ZjNiNDYz
|
15
|
-
OWJjZmViOGQ5MjI3OTdkNWZkOWVjNWRmMWE3ZTgwODIxMmZlYTk=
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 826fbd6c5365947f17fd05642eaf4d279f89c487
|
4
|
+
data.tar.gz: 15503d2beee58278dff7965eb18425b01dad8f75
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: bb065590dec9e6079623b5b63736a35c55a2534bbf199be151d0a22cb8ec20974f2a3325c39d165a6eaf55b7161094e8611ad51038838456de75ae3a7f4c5a0b
|
7
|
+
data.tar.gz: eda987423e80d6aa1d544dff2dd3b8deabb4ce7e149da8d84becbd2ff4d8091a39537370b600fba0e56089580b6ef0b5cbf938fdbc1e8b670f18ba5ce644f789
|
data/.travis.yml
CHANGED
data/CHANGELOG.md
CHANGED
@@ -1,9 +1,13 @@
|
|
1
1
|
# Publish Change History
|
2
2
|
|
3
|
-
## Next Release
|
3
|
+
## Next Release
|
4
4
|
|
5
5
|
* TODO
|
6
6
|
|
7
|
+
## 0.4.0 - 2013-12-17
|
8
|
+
|
9
|
+
* Tested against rails 4 and mongoid master only
|
10
|
+
|
7
11
|
## 0.3.0 - 2013-04-04
|
8
12
|
|
9
13
|
* Changes published_at field type from Date to Time
|
data/Gemfile
CHANGED
data/README.md
CHANGED
data/publish.gemspec
CHANGED
@@ -1,27 +1,25 @@
|
|
1
|
-
|
2
|
-
require "mongoid/publish/version"
|
1
|
+
# -*- encoding: utf-8 -*-
|
2
|
+
require File.expand_path("../lib/mongoid/publish/version", __FILE__)
|
3
3
|
|
4
4
|
Gem::Specification.new do |gem|
|
5
|
-
|
6
|
-
gem.name = "publish"
|
7
5
|
gem.authors = ["Lucas Renan", "Tiago Rafael Godinho", "Marco Singer"]
|
8
6
|
gem.email = ["contato@lucasrenan.com", "tiagogodinho3@gmail.com", "markaum@gmail.com"]
|
9
7
|
gem.description = %q{Adds the functionality to publish/unpublish mongoid docs}
|
10
8
|
gem.summary = %q{Adds the functionality to publish/unpublish mongoid docs}
|
11
9
|
gem.homepage = "https://github.com/lucasrenan/publish"
|
12
10
|
|
13
|
-
gem.
|
14
|
-
gem.
|
15
|
-
gem.test_files =
|
11
|
+
gem.files = `git ls-files`.split($\)
|
12
|
+
gem.executables = gem.files.grep(%r{^bin/}).map{ |f| File.basename(f) }
|
13
|
+
gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
|
14
|
+
gem.name = "publish"
|
16
15
|
gem.require_paths = ["lib"]
|
17
16
|
gem.version = Mongoid::Publish::VERSION
|
18
|
-
gem.
|
19
|
-
|
17
|
+
gem.license = "MIT"
|
20
18
|
|
21
19
|
gem.add_dependency "mongoid", ">= 3.1.0"
|
22
20
|
|
23
|
-
gem.add_development_dependency "rails", "
|
24
|
-
gem.add_development_dependency "rake", "~> 10.0"
|
25
|
-
gem.add_development_dependency "simplecov", "~> 0.
|
26
|
-
gem.add_development_dependency "timecop", "~> 0.
|
27
|
-
end
|
21
|
+
gem.add_development_dependency "rails", "~> 4.0.0"
|
22
|
+
gem.add_development_dependency "rake", "~> 10.1.0"
|
23
|
+
gem.add_development_dependency "simplecov", "~> 0.8.0"
|
24
|
+
gem.add_development_dependency "timecop", "~> 0.7.0"
|
25
|
+
end
|
@@ -1,11 +1,13 @@
|
|
1
1
|
require File.expand_path('../boot', __FILE__)
|
2
2
|
|
3
|
-
|
3
|
+
# Pick the frameworks you want:
|
4
|
+
# require "active_record/railtie"
|
4
5
|
require "action_controller/railtie"
|
5
|
-
require "action_view/railtie"
|
6
6
|
require "action_mailer/railtie"
|
7
|
+
require "sprockets/railtie"
|
8
|
+
# require "rails/test_unit/railtie"
|
7
9
|
|
8
|
-
Bundler.require
|
10
|
+
Bundler.require(*Rails.groups)
|
9
11
|
require "publish"
|
10
12
|
|
11
13
|
module Dummy
|
@@ -14,16 +16,6 @@ module Dummy
|
|
14
16
|
# Application configuration should go into files in config/initializers
|
15
17
|
# -- all .rb files in that directory are automatically loaded.
|
16
18
|
|
17
|
-
# Custom directories with classes and modules you want to be autoloadable.
|
18
|
-
# config.autoload_paths += %W(#{config.root}/extras)
|
19
|
-
|
20
|
-
# Only load the plugins named here, in the order given (default is alphabetical).
|
21
|
-
# :all can be used as a placeholder for all plugins not explicitly named.
|
22
|
-
# config.plugins = [ :exception_notification, :ssl_requirement, :all ]
|
23
|
-
|
24
|
-
# Activate observers that should always be running.
|
25
|
-
# config.active_record.observers = :cacher, :garbage_collector, :forum_observer
|
26
|
-
|
27
19
|
# Set Time.zone default to the specified zone and make Active Record auto-convert to this zone.
|
28
20
|
# Run "rake -D time" for a list of tasks for finding time zone names. Default is UTC.
|
29
21
|
# config.time_zone = 'Central Time (US & Canada)'
|
@@ -31,14 +23,5 @@ module Dummy
|
|
31
23
|
# The default locale is :en and all translations from config/locales/*.rb,yml are auto loaded.
|
32
24
|
# config.i18n.load_path += Dir[Rails.root.join('my', 'locales', '*.{rb,yml}').to_s]
|
33
25
|
# config.i18n.default_locale = :de
|
34
|
-
|
35
|
-
# JavaScript files you want as :defaults (application.js is always included).
|
36
|
-
# config.action_view.javascript_expansions[:defaults] = %w(jquery rails)
|
37
|
-
|
38
|
-
# Configure the default encoding used in templates for Ruby 1.9.
|
39
|
-
config.encoding = "utf-8"
|
40
|
-
|
41
|
-
# Configure sensitive parameters which will be filtered from the log file.
|
42
|
-
config.filter_parameters += [:password]
|
43
26
|
end
|
44
27
|
end
|
data/test/dummy/config/boot.rb
CHANGED
@@ -1,10 +1,5 @@
|
|
1
|
-
|
2
|
-
|
1
|
+
# Set up gems listed in the Gemfile.
|
2
|
+
ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../../../Gemfile', __FILE__)
|
3
3
|
|
4
|
-
if File.
|
5
|
-
|
6
|
-
require 'bundler'
|
7
|
-
Bundler.setup
|
8
|
-
end
|
9
|
-
|
10
|
-
$:.unshift File.expand_path('../../../../lib', __FILE__)
|
4
|
+
require 'bundler/setup' if File.exists?(ENV['BUNDLE_GEMFILE'])
|
5
|
+
$LOAD_PATH.unshift File.expand_path('../../../../lib', __FILE__)
|
@@ -1,30 +1,27 @@
|
|
1
1
|
Dummy::Application.configure do
|
2
|
-
# Settings specified here will take precedence over those in config/application.rb
|
2
|
+
# Settings specified here will take precedence over those in config/application.rb.
|
3
3
|
|
4
4
|
# In the development environment your application's code is reloaded on
|
5
5
|
# every request. This slows down response time but is perfect for development
|
6
6
|
# since you don't have to restart the web server when you make code changes.
|
7
7
|
config.cache_classes = false
|
8
8
|
|
9
|
-
#
|
10
|
-
config.
|
9
|
+
# Do not eager load code on boot.
|
10
|
+
config.eager_load = false
|
11
11
|
|
12
|
-
# Show full error reports and disable caching
|
12
|
+
# Show full error reports and disable caching.
|
13
13
|
config.consider_all_requests_local = true
|
14
14
|
config.action_controller.perform_caching = false
|
15
15
|
|
16
|
-
# Don't care if the mailer can't send
|
16
|
+
# Don't care if the mailer can't send.
|
17
17
|
config.action_mailer.raise_delivery_errors = false
|
18
18
|
|
19
|
-
# Print deprecation notices to the Rails logger
|
19
|
+
# Print deprecation notices to the Rails logger.
|
20
20
|
config.active_support.deprecation = :log
|
21
21
|
|
22
|
-
# Only use best-standards-support built into browsers
|
23
|
-
config.action_dispatch.best_standards_support = :builtin
|
24
22
|
|
25
|
-
#
|
26
|
-
|
27
|
-
|
28
|
-
# Expands the lines which load the assets
|
23
|
+
# Debug mode disables concatenation and preprocessing of assets.
|
24
|
+
# This option may cause significant delays in view rendering with a large
|
25
|
+
# number of complex assets.
|
29
26
|
config.assets.debug = true
|
30
|
-
end
|
27
|
+
end
|
@@ -1,5 +1,5 @@
|
|
1
1
|
Dummy::Application.configure do
|
2
|
-
# Settings specified here will take precedence over those in config/application.rb
|
2
|
+
# Settings specified here will take precedence over those in config/application.rb.
|
3
3
|
|
4
4
|
# The test environment is used exclusively to run your application's
|
5
5
|
# test suite. You never need to work with it otherwise. Remember that
|
@@ -7,28 +7,30 @@ Dummy::Application.configure do
|
|
7
7
|
# and recreated between test runs. Don't rely on the data there!
|
8
8
|
config.cache_classes = true
|
9
9
|
|
10
|
-
#
|
11
|
-
|
12
|
-
|
10
|
+
# Do not eager load code on boot. This avoids loading your whole application
|
11
|
+
# just for the purpose of running a single test. If you are using a tool that
|
12
|
+
# preloads Rails for running tests, you may have to set it to true.
|
13
|
+
config.eager_load = false
|
13
14
|
|
14
|
-
#
|
15
|
-
config.
|
15
|
+
# Configure static asset server for tests with Cache-Control for performance.
|
16
|
+
config.serve_static_assets = true
|
17
|
+
config.static_cache_control = "public, max-age=3600"
|
16
18
|
|
17
|
-
# Show full error reports and disable caching
|
19
|
+
# Show full error reports and disable caching.
|
18
20
|
config.consider_all_requests_local = true
|
19
21
|
config.action_controller.perform_caching = false
|
20
22
|
|
21
|
-
# Raise exceptions instead of rendering exception templates
|
23
|
+
# Raise exceptions instead of rendering exception templates.
|
22
24
|
config.action_dispatch.show_exceptions = false
|
23
25
|
|
24
|
-
# Disable request forgery protection in test environment
|
25
|
-
config.action_controller.allow_forgery_protection
|
26
|
+
# Disable request forgery protection in test environment.
|
27
|
+
config.action_controller.allow_forgery_protection = false
|
26
28
|
|
27
29
|
# Tell Action Mailer not to deliver emails to the real world.
|
28
30
|
# The :test delivery method accumulates sent emails in the
|
29
31
|
# ActionMailer::Base.deliveries array.
|
30
32
|
config.action_mailer.delivery_method = :test
|
31
33
|
|
32
|
-
# Print deprecation notices to the stderr
|
34
|
+
# Print deprecation notices to the stderr.
|
33
35
|
config.active_support.deprecation = :stderr
|
34
|
-
end
|
36
|
+
end
|
@@ -1,8 +1,3 @@
|
|
1
1
|
# Be sure to restart your server when you modify this file.
|
2
2
|
|
3
|
-
Dummy::Application.config.session_store :cookie_store, :
|
4
|
-
|
5
|
-
# Use the database for sessions instead of the cookie-based default,
|
6
|
-
# which shouldn't be used to store highly confidential information
|
7
|
-
# (create the session table with "rails generate session_migration")
|
8
|
-
# Dummy::Application.config.session_store :active_record_store
|
3
|
+
Dummy::Application.config.session_store :cookie_store, key: '_dummy_session'
|
@@ -5,26 +5,30 @@ development:
|
|
5
5
|
default:
|
6
6
|
# Defines the name of the default database that Mongoid can connect to.
|
7
7
|
# (required).
|
8
|
-
database:
|
8
|
+
database: publish_dummy_development
|
9
9
|
# Provides the hosts the default session can connect to. Must be an array
|
10
10
|
# of host:port pairs. (required)
|
11
11
|
hosts:
|
12
12
|
- localhost:27017
|
13
13
|
options:
|
14
|
-
# Change
|
15
|
-
#
|
16
|
-
#
|
14
|
+
# Change the default write concern. (default = { w: 1 })
|
15
|
+
# write:
|
16
|
+
# w: 1
|
17
17
|
|
18
|
-
# Change the default consistency model to
|
19
|
-
#
|
20
|
-
# to master. (default:
|
21
|
-
|
18
|
+
# Change the default consistency model to primary, secondary.
|
19
|
+
# 'secondary' will send reads to secondaries, 'primary' sends everything
|
20
|
+
# to master. (default: primary)
|
21
|
+
# read: secondary_preferred
|
22
|
+
|
23
|
+
# How many times Moped should attempt to retry an operation after
|
24
|
+
# failure. (default: 30)
|
25
|
+
# max_retries: 30
|
26
|
+
|
27
|
+
# The time in seconds that Moped should wait before retrying an
|
28
|
+
# operation on failure. (default: 1)
|
29
|
+
# retry_interval: 1
|
22
30
|
# Configure Mongoid specific options. (optional)
|
23
31
|
options:
|
24
|
-
# Configuration for whether or not to allow access to fields that do
|
25
|
-
# not have a field definition on the model. (default: true)
|
26
|
-
# allow_dynamic_fields: true
|
27
|
-
|
28
32
|
# Enable the identity map, needed for eager loading. (default: false)
|
29
33
|
# identity_map_enabled: false
|
30
34
|
|
@@ -53,7 +57,7 @@ development:
|
|
53
57
|
# admin access. (default: false)
|
54
58
|
# skip_version_check: false
|
55
59
|
|
56
|
-
#
|
60
|
+
# Use Active Support's time zone in conversions. (default: true)
|
57
61
|
# use_activesupport_time_zone: true
|
58
62
|
|
59
63
|
# Ensure all times are UTC in the app side. (default: false)
|
@@ -61,8 +65,12 @@ development:
|
|
61
65
|
test:
|
62
66
|
sessions:
|
63
67
|
default:
|
64
|
-
database:
|
68
|
+
database: publish_dummy_test
|
65
69
|
hosts:
|
66
70
|
- localhost:27017
|
67
71
|
options:
|
68
|
-
|
72
|
+
read: primary
|
73
|
+
# In the test environment we lower the retries and retry interval to
|
74
|
+
# low amounts for fast failures.
|
75
|
+
max_retries: 1
|
76
|
+
retry_interval: 0
|
data/test/dummy/config/routes.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: publish
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.4.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Lucas Renan
|
@@ -10,78 +10,78 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2013-
|
13
|
+
date: 2013-12-17 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: mongoid
|
17
17
|
requirement: !ruby/object:Gem::Requirement
|
18
18
|
requirements:
|
19
|
-
- -
|
19
|
+
- - '>='
|
20
20
|
- !ruby/object:Gem::Version
|
21
21
|
version: 3.1.0
|
22
22
|
type: :runtime
|
23
23
|
prerelease: false
|
24
24
|
version_requirements: !ruby/object:Gem::Requirement
|
25
25
|
requirements:
|
26
|
-
- -
|
26
|
+
- - '>='
|
27
27
|
- !ruby/object:Gem::Version
|
28
28
|
version: 3.1.0
|
29
29
|
- !ruby/object:Gem::Dependency
|
30
30
|
name: rails
|
31
31
|
requirement: !ruby/object:Gem::Requirement
|
32
32
|
requirements:
|
33
|
-
- -
|
33
|
+
- - ~>
|
34
34
|
- !ruby/object:Gem::Version
|
35
|
-
version:
|
35
|
+
version: 4.0.0
|
36
36
|
type: :development
|
37
37
|
prerelease: false
|
38
38
|
version_requirements: !ruby/object:Gem::Requirement
|
39
39
|
requirements:
|
40
|
-
- -
|
40
|
+
- - ~>
|
41
41
|
- !ruby/object:Gem::Version
|
42
|
-
version:
|
42
|
+
version: 4.0.0
|
43
43
|
- !ruby/object:Gem::Dependency
|
44
44
|
name: rake
|
45
45
|
requirement: !ruby/object:Gem::Requirement
|
46
46
|
requirements:
|
47
47
|
- - ~>
|
48
48
|
- !ruby/object:Gem::Version
|
49
|
-
version:
|
49
|
+
version: 10.1.0
|
50
50
|
type: :development
|
51
51
|
prerelease: false
|
52
52
|
version_requirements: !ruby/object:Gem::Requirement
|
53
53
|
requirements:
|
54
54
|
- - ~>
|
55
55
|
- !ruby/object:Gem::Version
|
56
|
-
version:
|
56
|
+
version: 10.1.0
|
57
57
|
- !ruby/object:Gem::Dependency
|
58
58
|
name: simplecov
|
59
59
|
requirement: !ruby/object:Gem::Requirement
|
60
60
|
requirements:
|
61
61
|
- - ~>
|
62
62
|
- !ruby/object:Gem::Version
|
63
|
-
version: 0.
|
63
|
+
version: 0.8.0
|
64
64
|
type: :development
|
65
65
|
prerelease: false
|
66
66
|
version_requirements: !ruby/object:Gem::Requirement
|
67
67
|
requirements:
|
68
68
|
- - ~>
|
69
69
|
- !ruby/object:Gem::Version
|
70
|
-
version: 0.
|
70
|
+
version: 0.8.0
|
71
71
|
- !ruby/object:Gem::Dependency
|
72
72
|
name: timecop
|
73
73
|
requirement: !ruby/object:Gem::Requirement
|
74
74
|
requirements:
|
75
75
|
- - ~>
|
76
76
|
- !ruby/object:Gem::Version
|
77
|
-
version: 0.
|
77
|
+
version: 0.7.0
|
78
78
|
type: :development
|
79
79
|
prerelease: false
|
80
80
|
version_requirements: !ruby/object:Gem::Requirement
|
81
81
|
requirements:
|
82
82
|
- - ~>
|
83
83
|
- !ruby/object:Gem::Version
|
84
|
-
version: 0.
|
84
|
+
version: 0.7.0
|
85
85
|
description: Adds the functionality to publish/unpublish mongoid docs
|
86
86
|
email:
|
87
87
|
- contato@lucasrenan.com
|
@@ -98,7 +98,6 @@ files:
|
|
98
98
|
- MIT-LICENSE
|
99
99
|
- README.md
|
100
100
|
- Rakefile
|
101
|
-
- gemfiles/mongoid-master.gemfile
|
102
101
|
- lib/mongoid/publish.rb
|
103
102
|
- lib/mongoid/publish/callbacks.rb
|
104
103
|
- lib/mongoid/publish/version.rb
|
@@ -108,7 +107,6 @@ files:
|
|
108
107
|
- test/dummy/app/controllers/application_controller.rb
|
109
108
|
- test/dummy/app/controllers/posts_controller.rb
|
110
109
|
- test/dummy/app/helpers/application_helper.rb
|
111
|
-
- test/dummy/app/helpers/posts_helper.rb
|
112
110
|
- test/dummy/app/models/post.rb
|
113
111
|
- test/dummy/app/models/product.rb
|
114
112
|
- test/dummy/app/views/layouts/application.html.erb
|
@@ -151,7 +149,8 @@ files:
|
|
151
149
|
- test/support/factories/products.rb
|
152
150
|
- test/test_helper.rb
|
153
151
|
homepage: https://github.com/lucasrenan/publish
|
154
|
-
licenses:
|
152
|
+
licenses:
|
153
|
+
- MIT
|
155
154
|
metadata: {}
|
156
155
|
post_install_message:
|
157
156
|
rdoc_options: []
|
@@ -159,17 +158,17 @@ require_paths:
|
|
159
158
|
- lib
|
160
159
|
required_ruby_version: !ruby/object:Gem::Requirement
|
161
160
|
requirements:
|
162
|
-
- -
|
161
|
+
- - '>='
|
163
162
|
- !ruby/object:Gem::Version
|
164
163
|
version: '0'
|
165
164
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
166
165
|
requirements:
|
167
|
-
- -
|
166
|
+
- - '>='
|
168
167
|
- !ruby/object:Gem::Version
|
169
168
|
version: '0'
|
170
169
|
requirements: []
|
171
170
|
rubyforge_project:
|
172
|
-
rubygems_version: 2.
|
171
|
+
rubygems_version: 2.1.11
|
173
172
|
signing_key:
|
174
173
|
specification_version: 4
|
175
174
|
summary: Adds the functionality to publish/unpublish mongoid docs
|
@@ -178,7 +177,6 @@ test_files:
|
|
178
177
|
- test/dummy/app/controllers/application_controller.rb
|
179
178
|
- test/dummy/app/controllers/posts_controller.rb
|
180
179
|
- test/dummy/app/helpers/application_helper.rb
|
181
|
-
- test/dummy/app/helpers/posts_helper.rb
|
182
180
|
- test/dummy/app/models/post.rb
|
183
181
|
- test/dummy/app/models/product.rb
|
184
182
|
- test/dummy/app/views/layouts/application.html.erb
|