mongoid-likeable 4.2.3 → 5.0.0.alpha1

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: f3eef147aacfedc2739b1ce15db221c88f028d68
4
- data.tar.gz: fb80c9c438f9986b15461f028d2c2baa219d7a1f
3
+ metadata.gz: d382d56cff72dc29a4bfdec20d833e824dc65ff3
4
+ data.tar.gz: d4c321c7d17d4ddabec2e6b3a6a85453d71802f0
5
5
  SHA512:
6
- metadata.gz: 250b61a3b621a7973f26243fe26f32046f564354552b6dc57b70e628f0a69965425828864418af21892f5856daeaf216610a0e017d68cf0fe659b9891c5ee784
7
- data.tar.gz: f58872332acae4b3e6229748430bc3ad261b6c3547f7b1ce6457e7d4320ea08451dd05b0221086e26a01c7698246543982b407bf317fc2253565dd2b4009cc7f
6
+ metadata.gz: 64b272aae533a39a6ab5e8f9f34fffb51172511174e3ccfeb7e0181b7191c3fb107f5e7790db276a17458ea1938ec16570769dd243b49af7443bba18d63b9346
7
+ data.tar.gz: ef0ab9bd09ae264d130fbc365f9e33d2a09eaa2f244acae822bdf4c1ff8613620bbd0832ac8139dfe6c4fd9acd4102c90a9e1b90b0c246df099a77d1dc5830cf
data/.editorconfig ADDED
@@ -0,0 +1,15 @@
1
+ # editorconfig.org
2
+
3
+ root = true
4
+
5
+ [*]
6
+ indent_style = space
7
+ indent_size = 2
8
+ end_of_line = lf
9
+ charset = utf-8
10
+ trim_trailing_whitespace = true
11
+ insert_final_newline = true
12
+
13
+ [*.py]
14
+ indent_style = space
15
+ indent_size = 4
data/.gitignore CHANGED
@@ -29,6 +29,7 @@ spec/reports
29
29
  test/tmp
30
30
  test/version_tmp
31
31
  tmp
32
+ .rvmrc
32
33
 
33
34
  # YARD artifacts
34
35
  .yardoc
@@ -36,3 +37,4 @@ _yardoc
36
37
  doc/
37
38
 
38
39
  Gemfile.lock
40
+ gemfiles/*.lock
data/.travis.yml CHANGED
@@ -1,5 +1,6 @@
1
1
  language: ruby
2
2
  rvm:
3
3
  - 1.9.3
4
+ - 2.0.0
4
5
  services:
5
6
  - mongodb
data/CHANGELOG.md CHANGED
@@ -1,3 +1,11 @@
1
+ 5.0.0.alpha1
2
+ ------------
3
+ * Mongoid 4 support
4
+ * Updated README
5
+ * Updated LICENSE
6
+ * Added CONTRIBUTING guidelines
7
+ * Added .editorconfig
8
+
1
9
  4.2.3
2
10
  -----
3
11
  * Added gem badge
data/CONTRIBUTING.md ADDED
@@ -0,0 +1,45 @@
1
+ # Contributing to mongoid-likeable
2
+
3
+ Looking to contribute something to mongoid-likeable? **Here's how you can help.**
4
+
5
+
6
+
7
+ ## Reporting issues
8
+
9
+ We only accept issues that are bug reports or feature requests. Bugs must be isolated and reproducible problems that we can fix within the mongoid-likeable core. Please read the following guidelines before opening any issue.
10
+
11
+ 1. **Search for existing issues.**
12
+ 2. **Create an isolated and reproducible test case.**
13
+ 3. **Include a live example if possible.**
14
+ 4. **Share as much information as possible.** Include at least Rails version, mongoid version and gem version. Also include steps to reproduce the bug.
15
+
16
+
17
+
18
+ ## Key branches
19
+
20
+ - `master` is the latest, deployed version. **Never make pull requests against this branch.**
21
+ - `develop` is the official development branch for the next release.
22
+
23
+ Take a look at [git-flow, A successful Git branching model](http://nvie.com/posts/a-successful-git-branching-model/)
24
+
25
+
26
+
27
+ ## Pull requests
28
+
29
+ - Try to submit pull requests against the `develop` branch for easier merging
30
+ - Try not to pollute your pull request with unintended changes--keep them simple and small
31
+ - **Test. Code coverage should never go below 100%.** If you find a bug, write at first a failing test case and then fix it.
32
+
33
+
34
+
35
+ ## Coding standards
36
+
37
+ ### Ruby
38
+
39
+ - [Ruby Styleguide](https://github.com/styleguide/ruby)
40
+
41
+
42
+
43
+ ## License
44
+
45
+ By contributing your code, you agree to license your contribution under the terms of the [BSD 2-Clause License](LICENSE)
data/LICENSE CHANGED
@@ -1,4 +1,4 @@
1
- Copyright (c) 2013, diowa
1
+ Copyright (c) 2014, diowa
2
2
  All rights reserved.
3
3
 
4
4
  Redistribution and use in source and binary forms, with or without
data/README.md CHANGED
@@ -8,7 +8,7 @@
8
8
  Add like to your Mongoid documents.
9
9
  This is a fork of `tombell/mongoid-voteable` for people who only need likes.
10
10
 
11
- **Note** Breaking changes from version 1.0 to 2.0. Check out our wiki for an update script
11
+
12
12
 
13
13
  ## Installation
14
14
 
@@ -20,10 +20,14 @@ or add the gem to your `Gemfile`
20
20
 
21
21
  gem 'mongoid-likeable'
22
22
 
23
+
24
+
23
25
  ## Thread safety
24
26
 
25
27
  This gem is thread safe.
26
28
 
29
+
30
+
27
31
  ## Usage
28
32
 
29
33
  Include the `Mongoid::Likeable` module into your models you want to like.
@@ -60,8 +64,52 @@ not called `_id` you can still pass the ID in as the second parameter instead.
60
64
  @story.liked? @user.id
61
65
  ```
62
66
 
63
- ## License
64
67
 
65
- mongoid-likeable is licensed under the BSD 2-Clause License
68
+
69
+ ## Contributing
70
+
71
+ Please read through our [contributing guidelines](CONTRIBUTING.md). Included are directions for opening issues, coding standards, and notes on development.
72
+
73
+ More over, if your pull request contains patches or features, you must include relevant unit tests.
74
+
75
+ Editor preferences are available in the [editor config](.editorconfig) for easy use in common text editors. Read more and download plugins at <http://editorconfig.org>.
76
+
77
+
78
+
79
+ ## Versioning
80
+
81
+ For transparency and insight into our release cycle, and for striving to maintain backward compatibility, Twbs Less Rails will be maintained under the Semantic Versioning guidelines as much as possible. Twbs Less Rails will not follow Bootstrap's version number.
82
+
83
+ Releases will be numbered with the following format:
84
+
85
+ `<major>.<minor>.<patch>`
86
+
87
+ And constructed with the following guidelines:
88
+
89
+ * Breaking backward compatibility bumps the major (and resets the minor and patch)
90
+ * New additions without breaking backward compatibility bumps the minor (and resets the patch)
91
+ * Bug fixes and misc changes bumps the patch
92
+
93
+ For more information on SemVer, please visit [http://semver.org/](http://semver.org/).
94
+
95
+
96
+
97
+ ## Authors
98
+
99
+ **Geremia Taglialatela**
100
+
101
+ + http://github.com/tagliala
102
+ + http://twitter.com/gtagliala
103
+
104
+ **Cesidio Di Landa**
105
+
106
+ + http://github.com/cesidio
107
+ + http://twitter.com/cesid
108
+
109
+
110
+
111
+ ## Copyright and license
112
+
113
+ Copyright 2014 diowa under [the BSD 2-Clause license](LICENSE).
66
114
 
67
115
  mongoid-voteable is licensed under the MIT License - Copyright (c) 2012 Tom Bell
data/Rakefile CHANGED
@@ -1,6 +1,6 @@
1
- task :default => :test
2
-
3
1
  require 'rake/testtask'
2
+ task :default => "test"
3
+
4
4
  Rake::TestTask.new(:test) do |test|
5
5
  test.libs << 'lib' << 'test'
6
6
  test.pattern = 'test/**/*_test.rb'
@@ -13,14 +13,14 @@ module Mongoid
13
13
  def like(liker)
14
14
  id = liker_id(liker)
15
15
  return if liked? id
16
- push :likers, id
16
+ push likers: id
17
17
  update_likers
18
18
  end
19
19
 
20
20
  def unlike(liker)
21
21
  id = liker_id(liker)
22
22
  return unless liked? id
23
- pull :likers, id
23
+ pull likers: id
24
24
  update_likers
25
25
  end
26
26
 
@@ -3,7 +3,7 @@ $:.push File.expand_path('../lib', __FILE__)
3
3
 
4
4
  Gem::Specification.new do |s|
5
5
  s.name = 'mongoid-likeable'
6
- s.version = '4.2.3'
6
+ s.version = '5.0.0.alpha1'
7
7
  s.platform = Gem::Platform::RUBY
8
8
  s.authors = ['diowa']
9
9
  s.email = ['dev@diowa.com']
@@ -14,7 +14,7 @@ Gem::Specification.new do |s|
14
14
 
15
15
  s.rubyforge_project = 'mongoid-likeable'
16
16
 
17
- s.add_dependency 'mongoid', '~> 3.1.5'
17
+ s.add_dependency 'mongoid', '>= 4.0.0.alpha1'
18
18
 
19
19
  s.add_development_dependency 'database_cleaner'
20
20
  s.add_development_dependency 'rake'
metadata CHANGED
@@ -1,29 +1,29 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mongoid-likeable
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.2.3
4
+ version: 5.0.0.alpha1
5
5
  platform: ruby
6
6
  authors:
7
7
  - diowa
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-10-16 00:00:00.000000000 Z
11
+ date: 2013-12-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: mongoid
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - ~>
17
+ - - '>='
18
18
  - !ruby/object:Gem::Version
19
- version: 3.1.5
19
+ version: 4.0.0.alpha1
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - ~>
24
+ - - '>='
25
25
  - !ruby/object:Gem::Version
26
- version: 3.1.5
26
+ version: 4.0.0.alpha1
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: database_cleaner
29
29
  requirement: !ruby/object:Gem::Requirement
@@ -102,9 +102,11 @@ extensions: []
102
102
  extra_rdoc_files: []
103
103
  files:
104
104
  - .coveralls.yml
105
+ - .editorconfig
105
106
  - .gitignore
106
107
  - .travis.yml
107
108
  - CHANGELOG.md
109
+ - CONTRIBUTING.md
108
110
  - Gemfile
109
111
  - LICENSE
110
112
  - README.md
@@ -131,12 +133,12 @@ required_ruby_version: !ruby/object:Gem::Requirement
131
133
  version: '0'
132
134
  required_rubygems_version: !ruby/object:Gem::Requirement
133
135
  requirements:
134
- - - '>='
136
+ - - '>'
135
137
  - !ruby/object:Gem::Version
136
- version: '0'
138
+ version: 1.3.1
137
139
  requirements: []
138
140
  rubyforge_project: mongoid-likeable
139
- rubygems_version: 2.0.6
141
+ rubygems_version: 2.1.11
140
142
  signing_key:
141
143
  specification_version: 4
142
144
  summary: Add likes to your Mongoid documents