string-strtr 0.0.1 → 0.0.2
Sign up to get free protection for your applications and to get access to all the features.
- data/VERSION +1 -1
- data/lib/string-strtr.rb +1 -1
- data/spec/string-strtr_spec.rb +2 -2
- data/string-strtr.gemspec +60 -0
- metadata +3 -2
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.0.
|
1
|
+
0.0.2
|
data/lib/string-strtr.rb
CHANGED
data/spec/string-strtr_spec.rb
CHANGED
@@ -3,10 +3,10 @@ require File.expand_path(File.dirname(__FILE__) + '/spec_helper')
|
|
3
3
|
describe "StringUtils" do
|
4
4
|
it "strtr" do
|
5
5
|
str = "\\\" \\ \" \\\\\""
|
6
|
-
res =
|
6
|
+
res = str.strtr(
|
7
7
|
"\\\\" => "\\",
|
8
8
|
"\\\"" => "\""
|
9
|
-
|
9
|
+
)
|
10
10
|
res.should eql("\" \\ \" \\\"")
|
11
11
|
end
|
12
12
|
end
|
@@ -0,0 +1,60 @@
|
|
1
|
+
# Generated by jeweler
|
2
|
+
# DO NOT EDIT THIS FILE DIRECTLY
|
3
|
+
# Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
|
4
|
+
# -*- encoding: utf-8 -*-
|
5
|
+
|
6
|
+
Gem::Specification.new do |s|
|
7
|
+
s.name = "string-strtr"
|
8
|
+
s.version = "0.0.2"
|
9
|
+
|
10
|
+
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
|
+
s.authors = ["Kasper Johansen"]
|
12
|
+
s.date = "2013-03-25"
|
13
|
+
s.description = "The method 'strtr' for Ruby known from PHP as a direct method under the String-class."
|
14
|
+
s.email = "kj@gfish.com"
|
15
|
+
s.extra_rdoc_files = [
|
16
|
+
"LICENSE.txt",
|
17
|
+
"README.rdoc"
|
18
|
+
]
|
19
|
+
s.files = [
|
20
|
+
".document",
|
21
|
+
".rspec",
|
22
|
+
"Gemfile",
|
23
|
+
"Gemfile.lock",
|
24
|
+
"LICENSE.txt",
|
25
|
+
"README.rdoc",
|
26
|
+
"Rakefile",
|
27
|
+
"VERSION",
|
28
|
+
"lib/string-strtr.rb",
|
29
|
+
"spec/spec_helper.rb",
|
30
|
+
"spec/string-strtr_spec.rb",
|
31
|
+
"string-strtr.gemspec"
|
32
|
+
]
|
33
|
+
s.homepage = "http://github.com/kaspernj/string-strtr"
|
34
|
+
s.licenses = ["MIT"]
|
35
|
+
s.require_paths = ["lib"]
|
36
|
+
s.rubygems_version = "1.8.25"
|
37
|
+
s.summary = "The method 'strtr' for Ruby known from PHP."
|
38
|
+
|
39
|
+
if s.respond_to? :specification_version then
|
40
|
+
s.specification_version = 3
|
41
|
+
|
42
|
+
if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
|
43
|
+
s.add_development_dependency(%q<rspec>, ["~> 2.8.0"])
|
44
|
+
s.add_development_dependency(%q<rdoc>, ["~> 3.12"])
|
45
|
+
s.add_development_dependency(%q<bundler>, [">= 1.0.0"])
|
46
|
+
s.add_development_dependency(%q<jeweler>, ["~> 1.8.4"])
|
47
|
+
else
|
48
|
+
s.add_dependency(%q<rspec>, ["~> 2.8.0"])
|
49
|
+
s.add_dependency(%q<rdoc>, ["~> 3.12"])
|
50
|
+
s.add_dependency(%q<bundler>, [">= 1.0.0"])
|
51
|
+
s.add_dependency(%q<jeweler>, ["~> 1.8.4"])
|
52
|
+
end
|
53
|
+
else
|
54
|
+
s.add_dependency(%q<rspec>, ["~> 2.8.0"])
|
55
|
+
s.add_dependency(%q<rdoc>, ["~> 3.12"])
|
56
|
+
s.add_dependency(%q<bundler>, [">= 1.0.0"])
|
57
|
+
s.add_dependency(%q<jeweler>, ["~> 1.8.4"])
|
58
|
+
end
|
59
|
+
end
|
60
|
+
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: string-strtr
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.2
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -95,6 +95,7 @@ files:
|
|
95
95
|
- lib/string-strtr.rb
|
96
96
|
- spec/spec_helper.rb
|
97
97
|
- spec/string-strtr_spec.rb
|
98
|
+
- string-strtr.gemspec
|
98
99
|
homepage: http://github.com/kaspernj/string-strtr
|
99
100
|
licenses:
|
100
101
|
- MIT
|
@@ -110,7 +111,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
110
111
|
version: '0'
|
111
112
|
segments:
|
112
113
|
- 0
|
113
|
-
hash:
|
114
|
+
hash: -3405512809448773112
|
114
115
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
115
116
|
none: false
|
116
117
|
requirements:
|