permalinker 1.0.1 → 1.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.markdown +8 -4
- data/permalinker-1.0.1.gem +0 -0
- data/permalinker.gemspec +2 -1
- metadata +16 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 948676c10897c9720f1511204bf0f4aeaa58f634
|
4
|
+
data.tar.gz: 8c2de61e02971df65f92ddda29fcfadd73dd721e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3819d6b2eeb321cb83bc57b54b2e6df020586b1d7032b1b4ce37516d0912d88f85c3c6e66ef061f27d95860a1f2f0680118026832a1eec8ef0a4b613be0a2cc0
|
7
|
+
data.tar.gz: 9d6264d55246e3c2f56a86af75757b5fa633f53b47717267d040f59f47354559a8d83ca13755f1b3ad84af075be15ee0d130df5a7284a1533c890976f2754286
|
data/README.markdown
CHANGED
@@ -34,12 +34,16 @@ The permalink is generated by replacing letters like "ä" to "ae", "ß" to "ss",
|
|
34
34
|
The permalink is created when `before_validation` callback is evaluated. This plugin also tries
|
35
35
|
to generate a permalink when `before_save` callback is evaluated and the instance has no permalink set.
|
36
36
|
|
37
|
-
You can
|
37
|
+
You can overwrite the permalink generation by setting the using the :overwrite_permalink attribute
|
38
38
|
|
39
|
-
|
40
|
-
|
41
|
-
end
|
39
|
+
@post.update_attributes(:overwrite_permalink => "this is my custom link")
|
40
|
+
# => @post.permalink = "1-this-is-my-custom-link"
|
42
41
|
|
42
|
+
To show an edit field wiith permalink value use
|
43
|
+
|
44
|
+
@post.permalink_value_without_id # => "this-is-my-custom-link"
|
45
|
+
|
46
|
+
|
43
47
|
## License
|
44
48
|
|
45
49
|
Copyright (c) 2011 Nando Vieira, released under the MIT license
|
Binary file
|
data/permalinker.gemspec
CHANGED
@@ -3,7 +3,7 @@ require "./lib/permalinker/version"
|
|
3
3
|
|
4
4
|
Gem::Specification.new do |s|
|
5
5
|
s.name = "permalinker"
|
6
|
-
s.version = "1.0.
|
6
|
+
s.version = "1.0.2"
|
7
7
|
s.platform = Gem::Platform::RUBY
|
8
8
|
s.authors = ["Florian Eck"]
|
9
9
|
s.email = ["it-support@friends-systems.de"]
|
@@ -16,6 +16,7 @@ Gem::Specification.new do |s|
|
|
16
16
|
s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
|
17
17
|
s.require_paths = ["lib"]
|
18
18
|
|
19
|
+
s.add_dependency "friendly_extensions"
|
19
20
|
s.add_development_dependency "activerecord"
|
20
21
|
s.add_development_dependency "sqlite3-ruby"
|
21
22
|
s.add_development_dependency "test-unit"
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: permalinker
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Florian Eck
|
@@ -10,6 +10,20 @@ bindir: bin
|
|
10
10
|
cert_chain: []
|
11
11
|
date: 2014-04-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: friendly_extensions
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - ">="
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '0'
|
20
|
+
type: :runtime
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - ">="
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '0'
|
13
27
|
- !ruby/object:Gem::Dependency
|
14
28
|
name: activerecord
|
15
29
|
requirement: !ruby/object:Gem::Requirement
|
@@ -155,6 +169,7 @@ files:
|
|
155
169
|
- lib/permalinker/orm/base.rb
|
156
170
|
- lib/permalinker/string_ext.rb
|
157
171
|
- lib/permalinker/version.rb
|
172
|
+
- permalinker-1.0.1.gem
|
158
173
|
- permalinker.gemspec
|
159
174
|
- spec/permalink/active_record_spec.rb
|
160
175
|
- spec/permalink/string_spec.rb
|