slugalizer 0.0.1 → 0.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/lib/slugalizer.rb +6 -1
- metadata +63 -9
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: fd9cc7b18ecbeb3c4a69d3f0658b7cb389615822
|
4
|
+
data.tar.gz: e97033448a7c1a6cb4fe4a997c87bb4f74be01df
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: fd622774d9ec6588f47137406a662148cb1ba092ba71e8cceb33e62b6fbbf81a7dc60a652d7b5a1f6b3343937ff599f64d55b68e4f2bb3a730f4c6d5781e3e32
|
7
|
+
data.tar.gz: 0a4cb184efcda5980fdf01a2d1d7361e5fcfa301be12950aa8fcfe4795a21f1b030279464da6b7e5dec13b5981304e7c4b40df83c3c35b4802d845a2a289f907
|
data/lib/slugalizer.rb
CHANGED
@@ -1,5 +1,7 @@
|
|
1
1
|
module Slugalizer
|
2
|
-
|
2
|
+
extend self
|
3
|
+
|
4
|
+
def to_slug(string = '')
|
3
5
|
#strip the string
|
4
6
|
ret = string.strip
|
5
7
|
|
@@ -16,6 +18,9 @@ module Slugalizer
|
|
16
18
|
#strip off leading/trailing dashes
|
17
19
|
ret.gsub! /\A[-\.]+|[-\.]+\z/,""
|
18
20
|
|
21
|
+
#transfor to downcase
|
22
|
+
ret.downcase!
|
23
|
+
|
19
24
|
ret
|
20
25
|
end
|
21
26
|
end
|
metadata
CHANGED
@@ -1,8 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: slugalizer
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
5
|
-
prerelease:
|
4
|
+
version: 0.0.2
|
6
5
|
platform: ruby
|
7
6
|
authors:
|
8
7
|
- Martín Aguilar
|
@@ -10,7 +9,63 @@ autorequire:
|
|
10
9
|
bindir: bin
|
11
10
|
cert_chain: []
|
12
11
|
date: 2015-09-10 00:00:00.000000000 Z
|
13
|
-
dependencies:
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: bundler
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - "~>"
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '1.6'
|
20
|
+
type: :development
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - "~>"
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '1.6'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: rake
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - ">="
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '0'
|
34
|
+
type: :development
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - ">="
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '0'
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: oktobertest
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - ">="
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: '0'
|
48
|
+
type: :development
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - ">="
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '0'
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: oktobertest-contrib
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - ">="
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '0'
|
62
|
+
type: :development
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - ">="
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: '0'
|
14
69
|
description: ''
|
15
70
|
email: martinaguilar@outlook.com
|
16
71
|
executables: []
|
@@ -21,26 +76,25 @@ files:
|
|
21
76
|
homepage: http://rubygems.org/gems/slugalizer
|
22
77
|
licenses:
|
23
78
|
- MIT
|
79
|
+
metadata: {}
|
24
80
|
post_install_message:
|
25
81
|
rdoc_options: []
|
26
82
|
require_paths:
|
27
83
|
- lib
|
28
84
|
required_ruby_version: !ruby/object:Gem::Requirement
|
29
|
-
none: false
|
30
85
|
requirements:
|
31
|
-
- -
|
86
|
+
- - ">="
|
32
87
|
- !ruby/object:Gem::Version
|
33
88
|
version: '0'
|
34
89
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
35
|
-
none: false
|
36
90
|
requirements:
|
37
|
-
- -
|
91
|
+
- - ">="
|
38
92
|
- !ruby/object:Gem::Version
|
39
93
|
version: '0'
|
40
94
|
requirements: []
|
41
95
|
rubyforge_project:
|
42
|
-
rubygems_version:
|
96
|
+
rubygems_version: 2.4.5
|
43
97
|
signing_key:
|
44
|
-
specification_version:
|
98
|
+
specification_version: 4
|
45
99
|
summary: One method slug generator.
|
46
100
|
test_files: []
|