realityforge-braid 0.9.2 → 0.9.3
Sign up to get free protection for your applications and to get access to all the features.
- data/.gitignore +0 -1
- data/Gemfile.lock +42 -0
- data/lib/braid/config.rb +9 -1
- data/lib/braid/version.rb +1 -1
- metadata +3 -2
data/.gitignore
CHANGED
data/Gemfile.lock
ADDED
@@ -0,0 +1,42 @@
|
|
1
|
+
PATH
|
2
|
+
remote: .
|
3
|
+
specs:
|
4
|
+
realityforge-braid (0.9.2)
|
5
|
+
main (>= 4.7.3)
|
6
|
+
open4 (>= 1.0.1)
|
7
|
+
|
8
|
+
GEM
|
9
|
+
remote: http://rubygems.org/
|
10
|
+
specs:
|
11
|
+
arrayfields (4.9.0)
|
12
|
+
chronic (0.9.1)
|
13
|
+
diff-lcs (1.1.3)
|
14
|
+
fattr (2.2.1)
|
15
|
+
main (5.2.0)
|
16
|
+
arrayfields (>= 4.7.4)
|
17
|
+
chronic (>= 0.6.2)
|
18
|
+
fattr (>= 2.2.0)
|
19
|
+
map (>= 5.1.0)
|
20
|
+
map (6.3.0)
|
21
|
+
metaclass (0.0.1)
|
22
|
+
mocha (0.13.3)
|
23
|
+
metaclass (~> 0.0.1)
|
24
|
+
open4 (1.3.0)
|
25
|
+
rake (10.0.3)
|
26
|
+
rspec (2.12.0)
|
27
|
+
rspec-core (~> 2.12.0)
|
28
|
+
rspec-expectations (~> 2.12.0)
|
29
|
+
rspec-mocks (~> 2.12.0)
|
30
|
+
rspec-core (2.12.2)
|
31
|
+
rspec-expectations (2.12.1)
|
32
|
+
diff-lcs (~> 1.1.3)
|
33
|
+
rspec-mocks (2.12.2)
|
34
|
+
|
35
|
+
PLATFORMS
|
36
|
+
ruby
|
37
|
+
|
38
|
+
DEPENDENCIES
|
39
|
+
mocha (>= 0.9.11)
|
40
|
+
rake
|
41
|
+
realityforge-braid!
|
42
|
+
rspec (= 2.12.0)
|
data/lib/braid/config.rb
CHANGED
@@ -60,6 +60,7 @@ module Braid
|
|
60
60
|
|
61
61
|
def remove(mirror)
|
62
62
|
@db.delete(mirror.path)
|
63
|
+
write_db
|
63
64
|
end
|
64
65
|
|
65
66
|
def update(mirror)
|
@@ -71,11 +72,18 @@ module Braid
|
|
71
72
|
private
|
72
73
|
def write_mirror(mirror)
|
73
74
|
@db[mirror.path] = clean_attributes(mirror.attributes)
|
75
|
+
write_db
|
76
|
+
end
|
77
|
+
|
78
|
+
def write_db
|
74
79
|
new_db = {}
|
75
80
|
@db.keys.sort.each do |key|
|
76
81
|
new_db[key] = @db[key]
|
77
82
|
end
|
78
|
-
File.open(@config_file, "wb")
|
83
|
+
File.open(@config_file, "wb") do |f|
|
84
|
+
f.write JSON.pretty_generate(new_db)
|
85
|
+
f.write "\n"
|
86
|
+
end
|
79
87
|
end
|
80
88
|
|
81
89
|
def clean_attributes(hash)
|
data/lib/braid/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: realityforge-braid
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.9.
|
4
|
+
version: 0.9.3
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2013-
|
13
|
+
date: 2013-08-08 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: main
|
@@ -88,6 +88,7 @@ files:
|
|
88
88
|
- .travis.yml
|
89
89
|
- CONTRIBUTING.md
|
90
90
|
- Gemfile
|
91
|
+
- Gemfile.lock
|
91
92
|
- LICENSE
|
92
93
|
- README.md
|
93
94
|
- Rakefile
|