rhubarb 0.4.0 → 0.4.2
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.
- data/Rakefile +25 -9
- data/VERSION +1 -1
- data/lib/rhubarb/persistence.rb +1 -1
- data/ruby-rhubarb.spec.in +43 -14
- data/test/test_rhubarb.rb +8 -8
- metadata +40 -70
- data/rhubarb.gemspec +0 -66
data/Rakefile
CHANGED
@@ -46,11 +46,11 @@ def name
|
|
46
46
|
end
|
47
47
|
|
48
48
|
def pkg_name
|
49
|
-
|
49
|
+
"ruby-#{name}"
|
50
50
|
end
|
51
51
|
|
52
52
|
def pkg_spec
|
53
|
-
|
53
|
+
"#{pkg_name}.spec"
|
54
54
|
end
|
55
55
|
|
56
56
|
def pkg_rel
|
@@ -58,7 +58,7 @@ def pkg_rel
|
|
58
58
|
end
|
59
59
|
|
60
60
|
def pkg_source
|
61
|
-
return pkg_name
|
61
|
+
return "#{pkg_name}-#{pkg_version}.tar.gz"
|
62
62
|
end
|
63
63
|
|
64
64
|
def pkg_dir
|
@@ -69,8 +69,27 @@ def rpm_dirs
|
|
69
69
|
return %w{BUILD BUILDROOT RPMS SOURCES SPECS SRPMS}
|
70
70
|
end
|
71
71
|
|
72
|
+
def package_prefix
|
73
|
+
"#{pkg_name}-#{pkg_version}"
|
74
|
+
end
|
75
|
+
|
76
|
+
def pristine_name
|
77
|
+
"#{package_prefix}.tar.gz"
|
78
|
+
end
|
79
|
+
|
80
|
+
desc "upload a pristine tarball for the current release to fedorahosted"
|
81
|
+
task :upload_pristine => [:pristine] do
|
82
|
+
raise "Please set FH_USERNAME" unless ENV['FH_USERNAME']
|
83
|
+
sh "scp #{pristine_name} #{ENV['FH_USERNAME']}@fedorahosted.org:grid"
|
84
|
+
end
|
85
|
+
|
86
|
+
desc "generate a pristine tarball for the tag corresponding to the current version"
|
87
|
+
task :pristine do
|
88
|
+
sh "git archive --format=tar v#{pkg_version} --prefix=#{package_prefix}/ | gzip -9nv > #{pristine_name}"
|
89
|
+
end
|
90
|
+
|
72
91
|
desc "create RPMs"
|
73
|
-
task :rpms => [:
|
92
|
+
task :rpms => [:tarball, :gen_spec] do
|
74
93
|
FileUtils.cp pkg_spec(), 'SPECS'
|
75
94
|
sh "rpmbuild --define=\"_topdir \${PWD}\" -ba SPECS/#{pkg_spec}"
|
76
95
|
end
|
@@ -81,11 +100,8 @@ task :gen_spec do
|
|
81
100
|
end
|
82
101
|
|
83
102
|
desc "Create a tarball"
|
84
|
-
task :tarball => [:make_rpmdirs, :
|
85
|
-
FileUtils.
|
86
|
-
FileUtils.cp ['LICENSE', 'README.rdoc', 'CHANGES', 'TODO', 'VERSION'], pkg_dir()
|
87
|
-
sh "tar -cf #{pkg_source} #{pkg_dir}"
|
88
|
-
FileUtils.mv pkg_source(), 'SOURCES'
|
103
|
+
task :tarball => [:make_rpmdirs, :pristine] do
|
104
|
+
FileUtils.cp pristine_name, 'SOURCES'
|
89
105
|
end
|
90
106
|
|
91
107
|
desc "Make dirs for building RPM"
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.4.
|
1
|
+
0.4.2
|
data/lib/rhubarb/persistence.rb
CHANGED
@@ -70,7 +70,7 @@ module Rhubarb
|
|
70
70
|
end
|
71
71
|
|
72
72
|
def self.sqlite_13
|
73
|
-
result = SQLite3.constants.include?("VERSION") && SQLite3::VERSION =~ /1\.3\.[0-9]+/
|
73
|
+
result = (SQLite3.constants.include?("VERSION") || SQLite3.constants.include?(:VERSION)) && SQLite3::VERSION =~ /1\.3\.[0-9]+/
|
74
74
|
!!result
|
75
75
|
end
|
76
76
|
|
data/ruby-rhubarb.spec.in
CHANGED
@@ -1,24 +1,38 @@
|
|
1
1
|
%{!?ruby_sitelib: %global ruby_sitelib %(ruby -rrbconfig -e 'puts Config::CONFIG["sitelibdir"] ')}
|
2
|
-
|
2
|
+
|
3
|
+
%if (0%{?fedora} == 0 && 0%{?rhel} <= 5)
|
4
|
+
%global building_for_el5 1
|
5
|
+
%else
|
6
|
+
%global building_for_el5 0
|
7
|
+
%endif
|
8
|
+
|
9
|
+
%if (0%{?fedora} >= 17)
|
10
|
+
%global ruby_abi 1.9.1
|
11
|
+
%else
|
12
|
+
%global ruby_abi 1.8
|
13
|
+
%endif
|
3
14
|
|
4
15
|
Summary: Simple versioned object-graph persistence layer
|
5
16
|
Name: ruby-rhubarb
|
6
17
|
Version: RHUBARB_VERSION
|
7
|
-
Release: %{
|
18
|
+
Release: 1%{?dist}
|
8
19
|
Group: Applications/System
|
9
20
|
License: ASL 2.0
|
10
21
|
URL: http://git.fedorahosted.org/git/grid/rhubarb.git
|
11
|
-
Source0:
|
22
|
+
Source0: https://fedorahosted.org/releases/g/r/grid/%{name}-%{version}.tar.gz
|
12
23
|
BuildRoot: %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)
|
13
24
|
Requires: ruby-sqlite3
|
14
25
|
Requires: ruby
|
15
|
-
Requires: ruby(abi) =
|
26
|
+
Requires: ruby(abi) = %{?ruby_abi}
|
27
|
+
Provides: ruby(rhubarb/rhubarb)
|
16
28
|
BuildRequires: ruby
|
17
29
|
BuildArch: noarch
|
18
30
|
|
19
31
|
%description
|
20
|
-
|
21
|
-
instances of specially-declared Ruby classes in a SQLite3 database
|
32
|
+
Rhubarb is a simple object-graph persistence layer that stores
|
33
|
+
instances of specially-declared Ruby classes in a SQLite3 database.
|
34
|
+
Notably, it supports multiple versions of objects and relationships
|
35
|
+
and plays nicely with the SPQR object publishing framework.
|
22
36
|
|
23
37
|
%prep
|
24
38
|
%setup -q
|
@@ -26,28 +40,43 @@ instances of specially-declared Ruby classes in a SQLite3 database
|
|
26
40
|
%build
|
27
41
|
|
28
42
|
%install
|
43
|
+
%if %{building_for_el5}
|
29
44
|
rm -rf %{buildroot}
|
45
|
+
%endif
|
30
46
|
mkdir -p %{buildroot}/%{ruby_sitelib}/rhubarb
|
31
47
|
mkdir -p %{buildroot}/%{ruby_sitelib}/rhubarb/mixins
|
32
48
|
cp -p -f lib/rhubarb/mixins/*.rb %{buildroot}/%{ruby_sitelib}/rhubarb/mixins
|
33
49
|
cp -p -f lib/rhubarb/*.rb %{buildroot}/%{ruby_sitelib}/rhubarb
|
34
50
|
|
51
|
+
%if %{building_for_el5}
|
35
52
|
%clean
|
36
53
|
rm -rf %{buildroot}
|
54
|
+
%endif
|
37
55
|
|
38
56
|
%files
|
57
|
+
%if %{building_for_el5}
|
39
58
|
%defattr(-, root, root, -)
|
59
|
+
%endif
|
40
60
|
%doc LICENSE README.rdoc CHANGES TODO VERSION
|
41
|
-
%{ruby_sitelib}/rhubarb/
|
42
|
-
%{ruby_sitelib}/rhubarb/classmixins.rb
|
43
|
-
%{ruby_sitelib}/rhubarb/mixins/freshness.rb
|
44
|
-
%{ruby_sitelib}/rhubarb/column.rb
|
45
|
-
%{ruby_sitelib}/rhubarb/reference.rb
|
46
|
-
%{ruby_sitelib}/rhubarb/util.rb
|
47
|
-
%{ruby_sitelib}/rhubarb/persisting.rb
|
48
|
-
%{ruby_sitelib}/rhubarb/persistence.rb
|
61
|
+
%{ruby_sitelib}/rhubarb/
|
49
62
|
|
50
63
|
%changelog
|
64
|
+
|
65
|
+
* Wed Feb 8 2011 willb <willb@redhat> - 0.4.2-1
|
66
|
+
- Fixes for running under Ruby 1.9
|
67
|
+
|
68
|
+
* Tue Oct 11 2011 willb <willb@redhat> - 0.4.1-1
|
69
|
+
- Updated to version 0.4.1, which exclusively includes build workflow improvements
|
70
|
+
|
71
|
+
* Wed Sep 21 2011 willb <willb@redhat> - 0.4.0-3
|
72
|
+
- specfile changes: conditionalized out all EL5 stuff
|
73
|
+
|
74
|
+
* Fri Sep 16 2011 willb <willb@redhat> - 0.4.0-2
|
75
|
+
- minor specfile changes.
|
76
|
+
|
77
|
+
* Wed Jul 6 2011 willb <willb@redhat> - 0.4.0-1
|
78
|
+
- now works with sqlite3-ruby 1.3.x (BZ 718016)
|
79
|
+
|
51
80
|
* Mon Jun 6 2011 willb <willb@redhat> - 0.3.0-3
|
52
81
|
- installation now preserves file modification times
|
53
82
|
|
data/test/test_rhubarb.rb
CHANGED
@@ -285,7 +285,7 @@ class NoPreparedStmtBackendTests < Test::Unit::TestCase
|
|
285
285
|
def test_instance_methods
|
286
286
|
["foo", "bar"].each do |prefix|
|
287
287
|
["#{prefix}", "#{prefix}="].each do |m|
|
288
|
-
assert TestClass.
|
288
|
+
assert TestClass.method_defined?(m), "#{m} method not declared in TestClass"
|
289
289
|
end
|
290
290
|
end
|
291
291
|
end
|
@@ -293,7 +293,7 @@ class NoPreparedStmtBackendTests < Test::Unit::TestCase
|
|
293
293
|
def test_instance_methods2
|
294
294
|
["fred", "barney"].each do |prefix|
|
295
295
|
["#{prefix}", "#{prefix}="].each do |m|
|
296
|
-
assert TestClass2.
|
296
|
+
assert TestClass2.method_defined?(m), "#{m} method not declared in TestClass2"
|
297
297
|
end
|
298
298
|
end
|
299
299
|
end
|
@@ -301,7 +301,7 @@ class NoPreparedStmtBackendTests < Test::Unit::TestCase
|
|
301
301
|
def test_instance_methods_neg
|
302
302
|
["fred", "barney"].each do |prefix|
|
303
303
|
["#{prefix}", "#{prefix}="].each do |m|
|
304
|
-
bogus_include = TestClass.
|
304
|
+
bogus_include = TestClass.method_defined? m
|
305
305
|
assert(bogus_include == false, "#{m} method declared in TestClass; shouldn't be")
|
306
306
|
end
|
307
307
|
end
|
@@ -345,7 +345,7 @@ class NoPreparedStmtBackendTests < Test::Unit::TestCase
|
|
345
345
|
def test_instance_methods_dont_include_class_methods
|
346
346
|
["foo", "bar"].each do |prefix|
|
347
347
|
["find_by_#{prefix}", "find_first_by_#{prefix}"].each do |m|
|
348
|
-
bogus_include = TestClass.
|
348
|
+
bogus_include = TestClass.method_defined? m
|
349
349
|
assert(bogus_include == false, "#{m} method declared in TestClass; shouldn't be")
|
350
350
|
end
|
351
351
|
end
|
@@ -362,7 +362,7 @@ class NoPreparedStmtBackendTests < Test::Unit::TestCase
|
|
362
362
|
["foo", "bar"].each do |prefix|
|
363
363
|
["find_by_#{prefix}", "find_first_by_#{prefix}"].each do |m|
|
364
364
|
klass = class << TestClass; self end
|
365
|
-
assert klass.
|
365
|
+
assert klass.method_defined?(m), "#{m} method not declared in TestClass' eigenclass"
|
366
366
|
end
|
367
367
|
end
|
368
368
|
end
|
@@ -371,7 +371,7 @@ class NoPreparedStmtBackendTests < Test::Unit::TestCase
|
|
371
371
|
["fred", "barney"].each do |prefix|
|
372
372
|
["find_by_#{prefix}", "find_first_by_#{prefix}"].each do |m|
|
373
373
|
klass = class << TestClass2; self end
|
374
|
-
assert klass.
|
374
|
+
assert klass.method_defined?(m), "#{m} method not declared in TestClass2's eigenclass"
|
375
375
|
end
|
376
376
|
end
|
377
377
|
end
|
@@ -385,7 +385,7 @@ class NoPreparedStmtBackendTests < Test::Unit::TestCase
|
|
385
385
|
include Rhubarb::Persisting
|
386
386
|
end
|
387
387
|
|
388
|
-
bogus_include = klass.
|
388
|
+
bogus_include = klass.method_defined?(m)
|
389
389
|
assert(bogus_include == false, "#{m} method declared in eigenclass of class including Rhubarb::Persisting; shouldn't be")
|
390
390
|
end
|
391
391
|
end
|
@@ -395,7 +395,7 @@ class NoPreparedStmtBackendTests < Test::Unit::TestCase
|
|
395
395
|
["fred", "barney"].each do |prefix|
|
396
396
|
["find_by_#{prefix}", "find_first_by_#{prefix}"].each do |m|
|
397
397
|
klass = class << TestClass; self end
|
398
|
-
bogus_include = klass.
|
398
|
+
bogus_include = klass.method_defined?(m)
|
399
399
|
assert(bogus_include == false, "#{m} method declared in TestClass' eigenclass; shouldn't be")
|
400
400
|
end
|
401
401
|
end
|
metadata
CHANGED
@@ -1,66 +1,49 @@
|
|
1
|
-
--- !ruby/object:Gem::Specification
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
2
|
name: rhubarb
|
3
|
-
version: !ruby/object:Gem::Version
|
4
|
-
|
5
|
-
prerelease:
|
6
|
-
segments:
|
7
|
-
- 0
|
8
|
-
- 4
|
9
|
-
- 0
|
10
|
-
version: 0.4.0
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.4.2
|
5
|
+
prerelease:
|
11
6
|
platform: ruby
|
12
|
-
authors:
|
7
|
+
authors:
|
13
8
|
- William Benton
|
14
9
|
autorequire:
|
15
10
|
bindir: bin
|
16
11
|
cert_chain: []
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
dependencies:
|
21
|
-
- !ruby/object:Gem::Dependency
|
12
|
+
date: 2012-02-08 00:00:00.000000000 Z
|
13
|
+
dependencies:
|
14
|
+
- !ruby/object:Gem::Dependency
|
22
15
|
name: rspec
|
23
|
-
|
24
|
-
requirement: &id001 !ruby/object:Gem::Requirement
|
16
|
+
requirement: &12227480 !ruby/object:Gem::Requirement
|
25
17
|
none: false
|
26
|
-
requirements:
|
27
|
-
- -
|
28
|
-
- !ruby/object:Gem::Version
|
29
|
-
hash: 13
|
30
|
-
segments:
|
31
|
-
- 1
|
32
|
-
- 2
|
33
|
-
- 9
|
18
|
+
requirements:
|
19
|
+
- - ! '>='
|
20
|
+
- !ruby/object:Gem::Version
|
34
21
|
version: 1.2.9
|
35
22
|
type: :development
|
36
|
-
version_requirements: *id001
|
37
|
-
- !ruby/object:Gem::Dependency
|
38
|
-
name: sqlite3-ruby
|
39
23
|
prerelease: false
|
40
|
-
|
24
|
+
version_requirements: *12227480
|
25
|
+
- !ruby/object:Gem::Dependency
|
26
|
+
name: sqlite3-ruby
|
27
|
+
requirement: &12223920 !ruby/object:Gem::Requirement
|
41
28
|
none: false
|
42
|
-
requirements:
|
43
|
-
- -
|
44
|
-
- !ruby/object:Gem::Version
|
45
|
-
hash: 27
|
46
|
-
segments:
|
47
|
-
- 1
|
48
|
-
- 2
|
49
|
-
- 2
|
29
|
+
requirements:
|
30
|
+
- - ! '>='
|
31
|
+
- !ruby/object:Gem::Version
|
50
32
|
version: 1.2.2
|
51
33
|
type: :runtime
|
52
|
-
|
53
|
-
|
34
|
+
prerelease: false
|
35
|
+
version_requirements: *12223920
|
36
|
+
description: Rhubarb is a simple object-graph persistence library implemented as a
|
37
|
+
mixin. It also works with the SPQR library for straightforward object publishing
|
38
|
+
over QMF.
|
54
39
|
email: willb@redhat.com
|
55
40
|
executables: []
|
56
|
-
|
57
41
|
extensions: []
|
58
|
-
|
59
|
-
extra_rdoc_files:
|
42
|
+
extra_rdoc_files:
|
60
43
|
- LICENSE
|
61
44
|
- README.rdoc
|
62
45
|
- TODO
|
63
|
-
files:
|
46
|
+
files:
|
64
47
|
- .document
|
65
48
|
- CHANGES
|
66
49
|
- LICENSE
|
@@ -76,44 +59,31 @@ files:
|
|
76
59
|
- lib/rhubarb/reference.rb
|
77
60
|
- lib/rhubarb/rhubarb.rb
|
78
61
|
- lib/rhubarb/util.rb
|
79
|
-
- rhubarb.gemspec
|
80
62
|
- ruby-rhubarb.spec.in
|
81
63
|
- test/helper.rb
|
82
64
|
- test/test_rhubarb.rb
|
83
|
-
has_rdoc: true
|
84
65
|
homepage: http://git.fedorahosted.org/git/grid/rhubarb.git
|
85
66
|
licenses: []
|
86
|
-
|
87
67
|
post_install_message:
|
88
68
|
rdoc_options: []
|
89
|
-
|
90
|
-
require_paths:
|
69
|
+
require_paths:
|
91
70
|
- lib
|
92
|
-
required_ruby_version: !ruby/object:Gem::Requirement
|
71
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
93
72
|
none: false
|
94
|
-
requirements:
|
95
|
-
- -
|
96
|
-
- !ruby/object:Gem::Version
|
97
|
-
|
98
|
-
|
99
|
-
- 0
|
100
|
-
version: "0"
|
101
|
-
required_rubygems_version: !ruby/object:Gem::Requirement
|
73
|
+
requirements:
|
74
|
+
- - ! '>='
|
75
|
+
- !ruby/object:Gem::Version
|
76
|
+
version: '0'
|
77
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
102
78
|
none: false
|
103
|
-
requirements:
|
104
|
-
- -
|
105
|
-
- !ruby/object:Gem::Version
|
106
|
-
|
107
|
-
segments:
|
108
|
-
- 0
|
109
|
-
version: "0"
|
79
|
+
requirements:
|
80
|
+
- - ! '>='
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: '0'
|
110
83
|
requirements: []
|
111
|
-
|
112
84
|
rubyforge_project:
|
113
|
-
rubygems_version: 1.
|
85
|
+
rubygems_version: 1.8.15
|
114
86
|
signing_key:
|
115
87
|
specification_version: 3
|
116
|
-
summary:
|
117
|
-
test_files:
|
118
|
-
- test/helper.rb
|
119
|
-
- test/test_rhubarb.rb
|
88
|
+
summary: ! 'Rhubarb: object graph persistence, easy as pie'
|
89
|
+
test_files: []
|
data/rhubarb.gemspec
DELETED
@@ -1,66 +0,0 @@
|
|
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 = %q{rhubarb}
|
8
|
-
s.version = "0.4.0"
|
9
|
-
|
10
|
-
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
|
-
s.authors = ["William Benton"]
|
12
|
-
s.date = %q{2011-07-06}
|
13
|
-
s.description = %q{Rhubarb is a simple object-graph persistence library implemented as a mixin. It also works with the SPQR library for straightforward object publishing over QMF.}
|
14
|
-
s.email = %q{willb@redhat.com}
|
15
|
-
s.extra_rdoc_files = [
|
16
|
-
"LICENSE",
|
17
|
-
"README.rdoc",
|
18
|
-
"TODO"
|
19
|
-
]
|
20
|
-
s.files = [
|
21
|
-
".document",
|
22
|
-
"CHANGES",
|
23
|
-
"LICENSE",
|
24
|
-
"README.rdoc",
|
25
|
-
"Rakefile",
|
26
|
-
"TODO",
|
27
|
-
"VERSION",
|
28
|
-
"lib/rhubarb/classmixins.rb",
|
29
|
-
"lib/rhubarb/column.rb",
|
30
|
-
"lib/rhubarb/mixins/freshness.rb",
|
31
|
-
"lib/rhubarb/persistence.rb",
|
32
|
-
"lib/rhubarb/persisting.rb",
|
33
|
-
"lib/rhubarb/reference.rb",
|
34
|
-
"lib/rhubarb/rhubarb.rb",
|
35
|
-
"lib/rhubarb/util.rb",
|
36
|
-
"rhubarb.gemspec",
|
37
|
-
"ruby-rhubarb.spec.in",
|
38
|
-
"test/helper.rb",
|
39
|
-
"test/test_rhubarb.rb"
|
40
|
-
]
|
41
|
-
s.homepage = %q{http://git.fedorahosted.org/git/grid/rhubarb.git}
|
42
|
-
s.require_paths = ["lib"]
|
43
|
-
s.rubygems_version = %q{1.3.7}
|
44
|
-
s.summary = %q{Rhubarb: object graph persistence, easy as pie}
|
45
|
-
s.test_files = [
|
46
|
-
"test/helper.rb",
|
47
|
-
"test/test_rhubarb.rb"
|
48
|
-
]
|
49
|
-
|
50
|
-
if s.respond_to? :specification_version then
|
51
|
-
current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
|
52
|
-
s.specification_version = 3
|
53
|
-
|
54
|
-
if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
|
55
|
-
s.add_development_dependency(%q<rspec>, [">= 1.2.9"])
|
56
|
-
s.add_runtime_dependency(%q<sqlite3-ruby>, [">= 1.2.2"])
|
57
|
-
else
|
58
|
-
s.add_dependency(%q<rspec>, [">= 1.2.9"])
|
59
|
-
s.add_dependency(%q<sqlite3-ruby>, [">= 1.2.2"])
|
60
|
-
end
|
61
|
-
else
|
62
|
-
s.add_dependency(%q<rspec>, [">= 1.2.9"])
|
63
|
-
s.add_dependency(%q<sqlite3-ruby>, [">= 1.2.2"])
|
64
|
-
end
|
65
|
-
end
|
66
|
-
|