druid-tools 0.3.0 → 0.3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +15 -0
- data/.gitignore +2 -1
- data/Gemfile +0 -1
- data/README.md +1 -1
- data/Rakefile +0 -3
- data/VERSION +1 -1
- data/druid-tools.gemspec +2 -3
- data/lib/druid_tools/druid.rb +0 -2
- data/spec/druid_tools_spec.rb +17 -17
- metadata +10 -32
- data/Gemfile.lock +0 -70
checksums.yaml
ADDED
@@ -0,0 +1,15 @@
|
|
1
|
+
---
|
2
|
+
!binary "U0hBMQ==":
|
3
|
+
metadata.gz: !binary |-
|
4
|
+
YzU3NjNlYTI1N2IwOTllYzQ0MjM4ZTg1N2YzYzBkMTQyMWY2ZTllOA==
|
5
|
+
data.tar.gz: !binary |-
|
6
|
+
MjRhMjQyMGRhODY3YTQ2NGZlMDFmZDE0MjU2NGZiYTFhZWJlNWI2ZA==
|
7
|
+
SHA512:
|
8
|
+
metadata.gz: !binary |-
|
9
|
+
YjY5ODdkMjUwYzlhZDEwNWI1OTI2MmFhMTc3Y2ZkZjgwNTM5MzI2YzliYzM4
|
10
|
+
YmJlZmIzMTFkNTUzMmI0MTY4YzIwYTcyNDQwMjdjM2IwN2RmODA4MmNkN2U2
|
11
|
+
MDMzNjE5NTcyYjA1ZmI5YjQ2YTcwZTdhMjM2ZThhY2NlZWRiMjA=
|
12
|
+
data.tar.gz: !binary |-
|
13
|
+
NGUwYTQ1YWM4YTdlY2VkZTJiYzA3ZTExZmFiOThhYjgwYmQ0NTQ4NjNhZWJh
|
14
|
+
YWMzNGM4NTYxMGY1OTI0YmQzMzk2YTI2MDQ3YTE5OWE3YzY5MDYyMDIxZmVl
|
15
|
+
NGMxOGI0Y2JmNWY2M2FkYmVlZjkzOGEwNGNiMDc5MGQwNDQ2YjE=
|
data/.gitignore
CHANGED
data/Gemfile
CHANGED
data/README.md
CHANGED
data/Rakefile
CHANGED
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.3.
|
1
|
+
0.3.1
|
data/druid-tools.gemspec
CHANGED
@@ -16,7 +16,6 @@ Gem::Specification.new do |gem|
|
|
16
16
|
gem.require_paths = ['lib']
|
17
17
|
gem.version = File.read('VERSION').strip
|
18
18
|
|
19
|
-
gem.add_development_dependency 'rake', '
|
20
|
-
gem.add_development_dependency 'rspec', '~>
|
21
|
-
gem.add_development_dependency 'lyberteam-gems-devel', '~> 1.0.0'
|
19
|
+
gem.add_development_dependency 'rake', '>= 10.1.0'
|
20
|
+
gem.add_development_dependency 'rspec', '~> 3.0'
|
22
21
|
end
|
data/lib/druid_tools/druid.rb
CHANGED
@@ -138,8 +138,6 @@ module DruidTools
|
|
138
138
|
prune_ancestors parent.parent
|
139
139
|
end
|
140
140
|
|
141
|
-
protected
|
142
|
-
|
143
141
|
# @param [Pathname] outermost_branch The branch at which pruning begins
|
144
142
|
# @return [void] Ascend the druid tree and prune empty branches
|
145
143
|
def prune_ancestors(outermost_branch)
|
data/spec/druid_tools_spec.rb
CHANGED
@@ -66,28 +66,28 @@ describe DruidTools::Druid do
|
|
66
66
|
end
|
67
67
|
|
68
68
|
it "should create and destroy druid directories" do
|
69
|
-
File.exists?(@tree_1).should
|
70
|
-
File.exists?(@tree_2).should
|
69
|
+
File.exists?(@tree_1).should eq false
|
70
|
+
File.exists?(@tree_2).should eq false
|
71
71
|
|
72
72
|
druid_1 = DruidTools::Druid.new(@druid_1,@fixture_dir)
|
73
73
|
druid_2 = DruidTools::Druid.new(@druid_2,@fixture_dir)
|
74
74
|
|
75
75
|
druid_1.mkdir
|
76
|
-
File.exists?(@tree_1).should
|
77
|
-
File.exists?(@tree_2).should
|
76
|
+
File.exists?(@tree_1).should eq true
|
77
|
+
File.exists?(@tree_2).should eq false
|
78
78
|
|
79
79
|
druid_2.mkdir
|
80
|
-
File.exists?(@tree_1).should
|
81
|
-
File.exists?(@tree_2).should
|
80
|
+
File.exists?(@tree_1).should eq true
|
81
|
+
File.exists?(@tree_2).should eq true
|
82
82
|
|
83
83
|
druid_2.rmdir
|
84
|
-
File.exists?(@tree_1).should
|
85
|
-
File.exists?(@tree_2).should
|
84
|
+
File.exists?(@tree_1).should eq true
|
85
|
+
File.exists?(@tree_2).should eq false
|
86
86
|
|
87
87
|
druid_1.rmdir
|
88
|
-
File.exists?(@tree_1).should
|
89
|
-
File.exists?(@tree_2).should
|
90
|
-
File.exists?(File.join(@fixture_dir,'cd')).should
|
88
|
+
File.exists?(@tree_1).should eq false
|
89
|
+
File.exists?(@tree_2).should eq false
|
90
|
+
File.exists?(File.join(@fixture_dir,'cd')).should eq false
|
91
91
|
end
|
92
92
|
|
93
93
|
describe "alternate prefixes" do
|
@@ -113,9 +113,9 @@ describe DruidTools::Druid do
|
|
113
113
|
druid.metadata_dir(false).should == File.join(@tree_1,'metadata')
|
114
114
|
druid.temp_dir(false).should == File.join(@tree_1,'temp')
|
115
115
|
|
116
|
-
File.exists?(File.join(@tree_1,'content')).should
|
117
|
-
File.exists?(File.join(@tree_1,'metadata')).should
|
118
|
-
File.exists?(File.join(@tree_1,'temp')).should
|
116
|
+
File.exists?(File.join(@tree_1,'content')).should eq false
|
117
|
+
File.exists?(File.join(@tree_1,'metadata')).should eq false
|
118
|
+
File.exists?(File.join(@tree_1,'temp')).should eq false
|
119
119
|
end
|
120
120
|
|
121
121
|
it "should create its content directories on the fly" do
|
@@ -124,9 +124,9 @@ describe DruidTools::Druid do
|
|
124
124
|
druid.metadata_dir.should == File.join(@tree_1,'metadata')
|
125
125
|
druid.temp_dir.should == File.join(@tree_1,'temp')
|
126
126
|
|
127
|
-
File.exists?(File.join(@tree_1,'content')).should
|
128
|
-
File.exists?(File.join(@tree_1,'metadata')).should
|
129
|
-
File.exists?(File.join(@tree_1,'temp')).should
|
127
|
+
File.exists?(File.join(@tree_1,'content')).should eq true
|
128
|
+
File.exists?(File.join(@tree_1,'metadata')).should eq true
|
129
|
+
File.exists?(File.join(@tree_1,'temp')).should eq true
|
130
130
|
end
|
131
131
|
|
132
132
|
it "should match glob" do
|
metadata
CHANGED
@@ -1,8 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: druid-tools
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
5
|
-
prerelease:
|
4
|
+
version: 0.3.1
|
6
5
|
platform: ruby
|
7
6
|
authors:
|
8
7
|
- Michael Klein
|
@@ -10,56 +9,36 @@ authors:
|
|
10
9
|
autorequire:
|
11
10
|
bindir: bin
|
12
11
|
cert_chain: []
|
13
|
-
date:
|
12
|
+
date: 2014-07-16 00:00:00.000000000 Z
|
14
13
|
dependencies:
|
15
14
|
- !ruby/object:Gem::Dependency
|
16
15
|
name: rake
|
17
16
|
requirement: !ruby/object:Gem::Requirement
|
18
|
-
none: false
|
19
17
|
requirements:
|
20
|
-
- -
|
18
|
+
- - ! '>='
|
21
19
|
- !ruby/object:Gem::Version
|
22
20
|
version: 10.1.0
|
23
21
|
type: :development
|
24
22
|
prerelease: false
|
25
23
|
version_requirements: !ruby/object:Gem::Requirement
|
26
|
-
none: false
|
27
24
|
requirements:
|
28
|
-
- -
|
25
|
+
- - ! '>='
|
29
26
|
- !ruby/object:Gem::Version
|
30
27
|
version: 10.1.0
|
31
28
|
- !ruby/object:Gem::Dependency
|
32
29
|
name: rspec
|
33
30
|
requirement: !ruby/object:Gem::Requirement
|
34
|
-
none: false
|
35
|
-
requirements:
|
36
|
-
- - ~>
|
37
|
-
- !ruby/object:Gem::Version
|
38
|
-
version: 2.14.0
|
39
|
-
type: :development
|
40
|
-
prerelease: false
|
41
|
-
version_requirements: !ruby/object:Gem::Requirement
|
42
|
-
none: false
|
43
|
-
requirements:
|
44
|
-
- - ~>
|
45
|
-
- !ruby/object:Gem::Version
|
46
|
-
version: 2.14.0
|
47
|
-
- !ruby/object:Gem::Dependency
|
48
|
-
name: lyberteam-gems-devel
|
49
|
-
requirement: !ruby/object:Gem::Requirement
|
50
|
-
none: false
|
51
31
|
requirements:
|
52
32
|
- - ~>
|
53
33
|
- !ruby/object:Gem::Version
|
54
|
-
version:
|
34
|
+
version: '3.0'
|
55
35
|
type: :development
|
56
36
|
prerelease: false
|
57
37
|
version_requirements: !ruby/object:Gem::Requirement
|
58
|
-
none: false
|
59
38
|
requirements:
|
60
39
|
- - ~>
|
61
40
|
- !ruby/object:Gem::Version
|
62
|
-
version:
|
41
|
+
version: '3.0'
|
63
42
|
description: Tools to manipulate DRUID trees and content directories
|
64
43
|
email:
|
65
44
|
- mbklein@stanford.edu
|
@@ -69,7 +48,6 @@ extra_rdoc_files: []
|
|
69
48
|
files:
|
70
49
|
- .gitignore
|
71
50
|
- Gemfile
|
72
|
-
- Gemfile.lock
|
73
51
|
- LICENSE
|
74
52
|
- README.md
|
75
53
|
- Rakefile
|
@@ -118,29 +96,29 @@ homepage: http://github.com/sul-dlss/druid-tools
|
|
118
96
|
licenses:
|
119
97
|
- ALv2
|
120
98
|
- Stanford University Libraries
|
99
|
+
metadata: {}
|
121
100
|
post_install_message:
|
122
101
|
rdoc_options: []
|
123
102
|
require_paths:
|
124
103
|
- lib
|
125
104
|
required_ruby_version: !ruby/object:Gem::Requirement
|
126
|
-
none: false
|
127
105
|
requirements:
|
128
106
|
- - ! '>='
|
129
107
|
- !ruby/object:Gem::Version
|
130
108
|
version: '0'
|
131
109
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
132
|
-
none: false
|
133
110
|
requirements:
|
134
111
|
- - ! '>='
|
135
112
|
- !ruby/object:Gem::Version
|
136
113
|
version: '0'
|
137
114
|
requirements: []
|
138
115
|
rubyforge_project:
|
139
|
-
rubygems_version:
|
116
|
+
rubygems_version: 2.2.2
|
140
117
|
signing_key:
|
141
|
-
specification_version:
|
118
|
+
specification_version: 4
|
142
119
|
summary: Tools to manipulate DRUID trees and content directories
|
143
120
|
test_files:
|
144
121
|
- spec/access_druid_spec.rb
|
145
122
|
- spec/druid_tools_spec.rb
|
146
123
|
- spec/spec_helper.rb
|
124
|
+
has_rdoc: true
|
data/Gemfile.lock
DELETED
@@ -1,70 +0,0 @@
|
|
1
|
-
PATH
|
2
|
-
remote: .
|
3
|
-
specs:
|
4
|
-
druid-tools (0.3.0)
|
5
|
-
|
6
|
-
GEM
|
7
|
-
remote: https://rubygems.org/
|
8
|
-
remote: http://sul-gems.stanford.edu/
|
9
|
-
specs:
|
10
|
-
coderay (1.0.9)
|
11
|
-
columnize (0.3.6)
|
12
|
-
debugger (1.6.2)
|
13
|
-
columnize (>= 0.3.1)
|
14
|
-
debugger-linecache (~> 1.2.0)
|
15
|
-
debugger-ruby_core_source (~> 1.2.3)
|
16
|
-
debugger-linecache (1.2.0)
|
17
|
-
debugger-ruby_core_source (1.2.3)
|
18
|
-
diff-lcs (1.2.4)
|
19
|
-
linecache (0.46)
|
20
|
-
rbx-require-relative (> 0.0.4)
|
21
|
-
lyberteam-gems-devel (1.0.1)
|
22
|
-
rake (>= 0.8.7)
|
23
|
-
rest-client
|
24
|
-
method_source (0.8.2)
|
25
|
-
mime-types (1.24)
|
26
|
-
multi_json (1.8.2)
|
27
|
-
pry (0.9.12.2)
|
28
|
-
coderay (~> 1.0.5)
|
29
|
-
method_source (~> 0.8)
|
30
|
-
slop (~> 3.4)
|
31
|
-
pry-debugger (0.2.2)
|
32
|
-
debugger (~> 1.3)
|
33
|
-
pry (~> 0.9.10)
|
34
|
-
rake (10.1.0)
|
35
|
-
rbx-require-relative (0.0.9)
|
36
|
-
rcov (1.0.0)
|
37
|
-
rest-client (1.6.7)
|
38
|
-
mime-types (>= 1.16)
|
39
|
-
rspec (2.14.1)
|
40
|
-
rspec-core (~> 2.14.0)
|
41
|
-
rspec-expectations (~> 2.14.0)
|
42
|
-
rspec-mocks (~> 2.14.0)
|
43
|
-
rspec-core (2.14.5)
|
44
|
-
rspec-expectations (2.14.2)
|
45
|
-
diff-lcs (>= 1.1.3, < 2.0)
|
46
|
-
rspec-mocks (2.14.3)
|
47
|
-
ruby-debug (0.10.4)
|
48
|
-
columnize (>= 0.1)
|
49
|
-
ruby-debug-base (~> 0.10.4.0)
|
50
|
-
ruby-debug-base (0.10.4)
|
51
|
-
linecache (>= 0.3)
|
52
|
-
simplecov (0.7.1)
|
53
|
-
multi_json (~> 1.0)
|
54
|
-
simplecov-html (~> 0.7.1)
|
55
|
-
simplecov-html (0.7.1)
|
56
|
-
slop (3.4.6)
|
57
|
-
|
58
|
-
PLATFORMS
|
59
|
-
ruby
|
60
|
-
|
61
|
-
DEPENDENCIES
|
62
|
-
debugger
|
63
|
-
druid-tools!
|
64
|
-
lyberteam-gems-devel (~> 1.0.0)
|
65
|
-
pry-debugger
|
66
|
-
rake (~> 10.1.0)
|
67
|
-
rcov
|
68
|
-
rspec (~> 2.14.0)
|
69
|
-
ruby-debug
|
70
|
-
simplecov
|