data_paths 0.3.0 → 0.3.1
Sign up to get free protection for your applications and to get access to all the features.
- data/.gitignore +6 -0
- data/ChangeLog.md +5 -0
- data/LICENSE.txt +1 -1
- data/README.md +3 -3
- data/Rakefile +5 -5
- data/data_paths.gemspec +34 -56
- data/gemspec.yml +3 -3
- data/lib/data_paths/version.rb +1 -1
- metadata +69 -54
data/ChangeLog.md
CHANGED
data/LICENSE.txt
CHANGED
data/README.md
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
# data_paths
|
2
2
|
|
3
|
-
* [Source](
|
4
|
-
* [Issues](
|
3
|
+
* [Source](https://github.com/postmodern/data_paths)
|
4
|
+
* [Issues](https://github.com/postmodern/data_paths/issues)
|
5
5
|
* [Documentation](http://rubydoc.info/gems/data_paths/frames)
|
6
6
|
* [Email](mailto:postmodern.mod3 at gmail.com)
|
7
7
|
|
@@ -80,6 +80,6 @@ static-content directories:
|
|
80
80
|
|
81
81
|
## Copyright
|
82
82
|
|
83
|
-
Copyright (c) 2011 Hal Brodigan
|
83
|
+
Copyright (c) 2011-2012 Hal Brodigan
|
84
84
|
|
85
85
|
See {file:LICENSE.txt} for license information.
|
data/Rakefile
CHANGED
@@ -2,13 +2,13 @@ require 'rubygems'
|
|
2
2
|
require 'rake'
|
3
3
|
|
4
4
|
begin
|
5
|
-
gem '
|
6
|
-
require '
|
5
|
+
gem 'rubygems-tasks', '~> 0.1'
|
6
|
+
require 'rubygems/tasks'
|
7
7
|
|
8
|
-
|
8
|
+
Gem::Tasks.new
|
9
9
|
rescue LoadError => e
|
10
10
|
STDERR.puts e.message
|
11
|
-
STDERR.puts "Run `gem install
|
11
|
+
STDERR.puts "Run `gem install rubygems-tasks` to install 'rubygems/tasks'."
|
12
12
|
end
|
13
13
|
|
14
14
|
begin
|
@@ -25,7 +25,7 @@ task :test => :spec
|
|
25
25
|
task :default => :spec
|
26
26
|
|
27
27
|
begin
|
28
|
-
gem 'yard', '~> 0.7
|
28
|
+
gem 'yard', '~> 0.7'
|
29
29
|
require 'yard'
|
30
30
|
|
31
31
|
YARD::Rake::YardocTask.new
|
data/data_paths.gemspec
CHANGED
@@ -3,92 +3,70 @@
|
|
3
3
|
require 'yaml'
|
4
4
|
|
5
5
|
Gem::Specification.new do |gemspec|
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
`hg manifest`.split($/)
|
10
|
-
elsif File.directory?('.svn')
|
11
|
-
`svn ls -R`.split($/).select { |path| File.file?(path) }
|
12
|
-
else
|
13
|
-
Dir['{**/}{.*,*}'].select { |path| File.file?(path) }
|
14
|
-
end
|
6
|
+
root = File.dirname(__FILE__)
|
7
|
+
lib_dir = File.join(root,'lib')
|
8
|
+
files = `git ls-files`.split($/)
|
15
9
|
|
16
10
|
filter_files = lambda { |paths|
|
17
|
-
case paths
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
11
|
+
files & case paths
|
12
|
+
when Array
|
13
|
+
paths
|
14
|
+
when String
|
15
|
+
Dir[paths]
|
16
|
+
end
|
23
17
|
}
|
24
18
|
|
25
19
|
version = {
|
26
|
-
:file
|
20
|
+
:file => 'data_paths/version',
|
27
21
|
:constant => 'DataPaths::VERSION'
|
28
22
|
}
|
29
23
|
|
30
24
|
defaults = {
|
31
|
-
'name'
|
32
|
-
'files'
|
33
|
-
'
|
34
|
-
'
|
35
|
-
'
|
25
|
+
'name' => File.basename(root),
|
26
|
+
'files' => files,
|
27
|
+
'require_paths' => ['ext', 'lib'].select { |dir| File.directory?(dir) },
|
28
|
+
'executables' => filter_files['bin/*'].map { |path| File.basename(path) },
|
29
|
+
'test_files' => filter_files['{test/{**/}*_test.rb,spec/{**/}*_spec.rb}'],
|
30
|
+
'doc_files' => filter_files['*.{txt,rdoc,md,markdown,tt,textile}'],
|
31
|
+
'extra_doc_files' => filter_files['*.{txt,rdoc,md,markdown,tt,textile}']
|
36
32
|
}
|
37
33
|
|
38
34
|
metadata = defaults.merge(YAML.load_file('gemspec.yml'))
|
39
35
|
|
40
|
-
gemspec.name
|
36
|
+
gemspec.name = metadata['name']
|
41
37
|
gemspec.version = if metadata['version']
|
42
38
|
metadata['version']
|
43
|
-
|
44
|
-
|
39
|
+
else
|
40
|
+
$LOAD_PATH << lib_dir unless $LOAD_PATH.include?(lib_dir)
|
41
|
+
|
42
|
+
require version[:file]
|
45
43
|
eval(version[:constant])
|
46
44
|
end
|
47
45
|
|
48
|
-
gemspec.summary
|
46
|
+
gemspec.summary = metadata.fetch('summary',metadata['description'])
|
49
47
|
gemspec.description = metadata.fetch('description',metadata['summary'])
|
50
48
|
|
51
|
-
|
52
|
-
|
53
|
-
gemspec.licenses = metadata['license']
|
54
|
-
when String
|
55
|
-
gemspec.license = metadata['license']
|
56
|
-
end
|
57
|
-
|
58
|
-
case metadata['authors']
|
59
|
-
when Array
|
60
|
-
gemspec.authors = metadata['authors']
|
61
|
-
when String
|
62
|
-
gemspec.author = metadata['authors']
|
63
|
-
end
|
49
|
+
gemspec.licenses = Array(metadata['license'])
|
50
|
+
gemspec.authors = Array(metadata['authors'])
|
64
51
|
|
65
|
-
gemspec.email
|
52
|
+
gemspec.email = metadata['email']
|
66
53
|
gemspec.homepage = metadata['homepage']
|
67
54
|
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
end
|
74
|
-
|
75
|
-
gemspec.files = filter_files[metadata['files']]
|
76
|
-
|
77
|
-
gemspec.executables = metadata['executables']
|
78
|
-
gemspec.extensions = metadata['extensions']
|
55
|
+
gemspec.require_paths = Array(metadata['require_paths'])
|
56
|
+
gemspec.files = filter_files[metadata['files']]
|
57
|
+
gemspec.files += Array(metadata['generated_files'])
|
58
|
+
gemspec.executables = metadata['executables']
|
59
|
+
gemspec.extensions = metadata['extensions']
|
79
60
|
|
80
61
|
if Gem::VERSION < '1.7.'
|
81
62
|
gemspec.default_executable = gemspec.executables.first
|
82
63
|
end
|
83
64
|
|
84
|
-
gemspec.test_files
|
85
|
-
|
86
|
-
unless gemspec.files.include?('.document')
|
87
|
-
gemspec.extra_rdoc_files = metadata['extra_doc_files']
|
88
|
-
end
|
65
|
+
gemspec.test_files = filter_files[metadata['test_files']]
|
66
|
+
gemspec.extra_rdoc_files = Array(metadata['extra_doc_files'])
|
89
67
|
|
90
68
|
gemspec.post_install_message = metadata['post_install_message']
|
91
|
-
gemspec.requirements
|
69
|
+
gemspec.requirements = metadata['requirements']
|
92
70
|
|
93
71
|
if gemspec.respond_to?(:required_ruby_version=)
|
94
72
|
gemspec.required_ruby_version = metadata['required_ruby_version']
|
data/gemspec.yml
CHANGED
@@ -9,10 +9,10 @@ description:
|
|
9
9
|
license: MIT
|
10
10
|
authors: Postmodern
|
11
11
|
email: postmodern.mod3@gmail.com
|
12
|
-
homepage:
|
12
|
+
homepage: https://github.com/postmodern/data_paths#readme
|
13
13
|
has_yard: true
|
14
14
|
|
15
15
|
development_dependencies:
|
16
|
-
|
16
|
+
rubygems-tasks: ~> 0.1
|
17
17
|
rspec: ~> 2.4
|
18
|
-
yard: ~> 0.7
|
18
|
+
yard: ~> 0.7
|
data/lib/data_paths/version.rb
CHANGED
metadata
CHANGED
@@ -1,61 +1,78 @@
|
|
1
|
-
--- !ruby/object:Gem::Specification
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
2
|
name: data_paths
|
3
|
-
version: !ruby/object:Gem::Version
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.3.1
|
4
5
|
prerelease:
|
5
|
-
version: 0.3.0
|
6
6
|
platform: ruby
|
7
|
-
authors:
|
7
|
+
authors:
|
8
8
|
- Postmodern
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
prerelease: false
|
18
|
-
requirement: &id001 !ruby/object:Gem::Requirement
|
12
|
+
date: 2012-05-28 00:00:00.000000000 Z
|
13
|
+
dependencies:
|
14
|
+
- !ruby/object:Gem::Dependency
|
15
|
+
name: rubygems-tasks
|
16
|
+
requirement: !ruby/object:Gem::Requirement
|
19
17
|
none: false
|
20
|
-
requirements:
|
18
|
+
requirements:
|
21
19
|
- - ~>
|
22
|
-
- !ruby/object:Gem::Version
|
23
|
-
version:
|
20
|
+
- !ruby/object:Gem::Version
|
21
|
+
version: '0.1'
|
24
22
|
type: :development
|
25
|
-
version_requirements: *id001
|
26
|
-
- !ruby/object:Gem::Dependency
|
27
|
-
name: rspec
|
28
23
|
prerelease: false
|
29
|
-
|
24
|
+
version_requirements: !ruby/object:Gem::Requirement
|
30
25
|
none: false
|
31
|
-
requirements:
|
26
|
+
requirements:
|
32
27
|
- - ~>
|
33
|
-
- !ruby/object:Gem::Version
|
34
|
-
version:
|
28
|
+
- !ruby/object:Gem::Version
|
29
|
+
version: '0.1'
|
30
|
+
- !ruby/object:Gem::Dependency
|
31
|
+
name: rspec
|
32
|
+
requirement: !ruby/object:Gem::Requirement
|
33
|
+
none: false
|
34
|
+
requirements:
|
35
|
+
- - ~>
|
36
|
+
- !ruby/object:Gem::Version
|
37
|
+
version: '2.4'
|
35
38
|
type: :development
|
36
|
-
version_requirements: *id002
|
37
|
-
- !ruby/object:Gem::Dependency
|
38
|
-
name: yard
|
39
39
|
prerelease: false
|
40
|
-
|
40
|
+
version_requirements: !ruby/object:Gem::Requirement
|
41
|
+
none: false
|
42
|
+
requirements:
|
43
|
+
- - ~>
|
44
|
+
- !ruby/object:Gem::Version
|
45
|
+
version: '2.4'
|
46
|
+
- !ruby/object:Gem::Dependency
|
47
|
+
name: yard
|
48
|
+
requirement: !ruby/object:Gem::Requirement
|
41
49
|
none: false
|
42
|
-
requirements:
|
50
|
+
requirements:
|
43
51
|
- - ~>
|
44
|
-
- !ruby/object:Gem::Version
|
45
|
-
version: 0.7
|
52
|
+
- !ruby/object:Gem::Version
|
53
|
+
version: '0.7'
|
46
54
|
type: :development
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
55
|
+
prerelease: false
|
56
|
+
version_requirements: !ruby/object:Gem::Requirement
|
57
|
+
none: false
|
58
|
+
requirements:
|
59
|
+
- - ~>
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '0.7'
|
62
|
+
description: DataPaths is a library to manage the paths of directories containing
|
63
|
+
static-content across multiple libraries. For example, DataPaths can manage the
|
64
|
+
`data/` directories of multiple RubyGems, in much the same way RubyGems manages
|
65
|
+
the paths of `lib/` directories using `$LOAD_PATH`.
|
66
|
+
email: postmodern.mod3@gmail.com
|
51
67
|
executables: []
|
52
|
-
|
53
68
|
extensions: []
|
54
|
-
|
55
|
-
|
69
|
+
extra_rdoc_files:
|
70
|
+
- ChangeLog.md
|
71
|
+
- LICENSE.txt
|
56
72
|
- README.md
|
57
|
-
files:
|
73
|
+
files:
|
58
74
|
- .gemtest
|
75
|
+
- .gitignore
|
59
76
|
- .rspec
|
60
77
|
- .yardopts
|
61
78
|
- ChangeLog.md
|
@@ -80,33 +97,31 @@ files:
|
|
80
97
|
- spec/helpers/data2/dir/two.txt
|
81
98
|
- spec/methods_examples.rb
|
82
99
|
- spec/spec_helper.rb
|
83
|
-
homepage:
|
84
|
-
licenses:
|
100
|
+
homepage: https://github.com/postmodern/data_paths#readme
|
101
|
+
licenses:
|
85
102
|
- MIT
|
86
103
|
post_install_message:
|
87
104
|
rdoc_options: []
|
88
|
-
|
89
|
-
require_paths:
|
105
|
+
require_paths:
|
90
106
|
- lib
|
91
|
-
required_ruby_version: !ruby/object:Gem::Requirement
|
107
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
92
108
|
none: false
|
93
|
-
requirements:
|
94
|
-
- -
|
95
|
-
- !ruby/object:Gem::Version
|
96
|
-
version:
|
97
|
-
required_rubygems_version: !ruby/object:Gem::Requirement
|
109
|
+
requirements:
|
110
|
+
- - ! '>='
|
111
|
+
- !ruby/object:Gem::Version
|
112
|
+
version: '0'
|
113
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
98
114
|
none: false
|
99
|
-
requirements:
|
100
|
-
- -
|
101
|
-
- !ruby/object:Gem::Version
|
102
|
-
version:
|
115
|
+
requirements:
|
116
|
+
- - ! '>='
|
117
|
+
- !ruby/object:Gem::Version
|
118
|
+
version: '0'
|
103
119
|
requirements: []
|
104
|
-
|
105
|
-
|
106
|
-
rubygems_version: 1.8.5
|
120
|
+
rubyforge_project:
|
121
|
+
rubygems_version: 1.8.24
|
107
122
|
signing_key:
|
108
123
|
specification_version: 3
|
109
124
|
summary: DataPaths is a library to manage multiple data/ directories.
|
110
|
-
test_files:
|
125
|
+
test_files:
|
111
126
|
- spec/data_paths_spec.rb
|
112
127
|
- spec/finders_spec.rb
|