netrc 0.7.1 → 0.7.2
Sign up to get free protection for your applications and to get access to all the features.
- data/changelog.txt +6 -0
- data/lib/netrc.rb +6 -6
- data/test/test_netrc.rb +1 -1
- metadata +5 -5
data/changelog.txt
CHANGED
data/lib/netrc.rb
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
class Netrc
|
2
|
-
VERSION = "0.7.
|
2
|
+
VERSION = "0.7.2"
|
3
3
|
WINDOWS = (RUBY_PLATFORM =~ /win32|mingw32/i)
|
4
4
|
|
5
5
|
def self.default_path
|
@@ -68,7 +68,7 @@ class Netrc
|
|
68
68
|
cur, item = [], []
|
69
69
|
|
70
70
|
def ts.take
|
71
|
-
if
|
71
|
+
if length < 1
|
72
72
|
raise Error, "unexpected EOF"
|
73
73
|
end
|
74
74
|
shift
|
@@ -76,14 +76,14 @@ class Netrc
|
|
76
76
|
|
77
77
|
def ts.readto
|
78
78
|
l = []
|
79
|
-
while
|
79
|
+
while length > 0 && ! yield(self[0])
|
80
80
|
l << shift
|
81
81
|
end
|
82
82
|
return l.join
|
83
83
|
end
|
84
84
|
|
85
85
|
pre = ts.readto{|t| t == "machine"}
|
86
|
-
while ts.
|
86
|
+
while ts.length > 0
|
87
87
|
cur << ts.take + ts.readto{|t| ! skip?(t)}
|
88
88
|
cur << ts.take
|
89
89
|
cur << ts.readto{|t| t == "login"} + ts.take + ts.readto{|t| ! skip?(t)}
|
@@ -120,8 +120,8 @@ class Netrc
|
|
120
120
|
end
|
121
121
|
end
|
122
122
|
|
123
|
-
def
|
124
|
-
@data.
|
123
|
+
def length
|
124
|
+
@data.length
|
125
125
|
end
|
126
126
|
|
127
127
|
def delete(key)
|
data/test/test_netrc.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: netrc
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.7.
|
4
|
+
version: 0.7.2
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -10,11 +10,11 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2012-
|
13
|
+
date: 2012-05-23 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: turn
|
17
|
-
requirement: &
|
17
|
+
requirement: &70325610509140 !ruby/object:Gem::Requirement
|
18
18
|
none: false
|
19
19
|
requirements:
|
20
20
|
- - ! '>='
|
@@ -22,7 +22,7 @@ dependencies:
|
|
22
22
|
version: '0'
|
23
23
|
type: :development
|
24
24
|
prerelease: false
|
25
|
-
version_requirements: *
|
25
|
+
version_requirements: *70325610509140
|
26
26
|
description: This library can read and update netrc files, preserving formatting including
|
27
27
|
comments and whitespace.
|
28
28
|
email: geemus@gmail.com
|
@@ -59,7 +59,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
59
59
|
version: '0'
|
60
60
|
requirements: []
|
61
61
|
rubyforge_project:
|
62
|
-
rubygems_version: 1.8.
|
62
|
+
rubygems_version: 1.8.15
|
63
63
|
signing_key:
|
64
64
|
specification_version: 3
|
65
65
|
summary: Library to read and write netrc files.
|