pkg-wizard 0.1.10 → 0.1.12

Sign up to get free protection for your applications and to get access to all the features.
data/Rakefile CHANGED
@@ -1,5 +1,6 @@
1
1
  require 'rubygems'
2
2
  require 'bundler'
3
+ require 'lib/pkg-wizard'
3
4
  begin
4
5
  Bundler.setup(:default, :development)
5
6
  rescue Bundler::BundlerError => e
@@ -13,7 +14,7 @@ require 'jeweler'
13
14
  Jeweler::Tasks.new do |gem|
14
15
  # gem is a Gem::Specification... see http://docs.rubygems.org/read/chapter/20 for more options
15
16
  gem.name = "pkg-wizard"
16
- gem.version = File.read 'VERSION'
17
+ gem.version = PKGWizard::VERSION
17
18
  gem.homepage = "http://github.com/rubiojr/pkg-wizard"
18
19
  gem.license = "MIT"
19
20
  gem.summary = %Q{Package Wizards Tools}
@@ -1,4 +1,9 @@
1
- require 'git'
1
+
2
+ begin
3
+ require 'git'
4
+ rescue Git::GitExecuteError => e
5
+ $stderr.puts "WARNING: Git is not installed in your system. Run pkgwiz init-env first."
6
+ end
2
7
 
3
8
  module PKGWizard
4
9
 
@@ -1,3 +1,5 @@
1
+ require 'fileutils'
2
+
1
3
  module PKGWizard
2
4
  class NoSpecFound < Exception; end
3
5
  class RPMBuildError < Exception; end
@@ -40,7 +42,7 @@ module PKGWizard
40
42
  pkg_release = File.read(specs.first).match(/Release:(.*?)$/)[1].strip.chomp.gsub(/%\{\?.*\}/, '')
41
43
  pkg_full_name = "#{pkg_name}-#{pkg_ver}-#{pkg_release}"
42
44
  %w(SOURCES SRPMS SPECS BUILDROOT RPMS BUILD).each do |d|
43
- Dir.mkdir File.join(File.expand_path(rpmbuild_dir), d) if not File.exist?(File.join(rpmbuild_dir, d))
45
+ FileUtils.mkdir_p File.join(File.expand_path(rpmbuild_dir), d) if not File.exist?(File.join(rpmbuild_dir, d))
44
46
  end
45
47
  Dir['*'].each do |f|
46
48
  FileUtils.cp(f, "#{rpmbuild_dir}/SOURCES") if not File.directory?(f)
data/lib/pkg-wizard.rb CHANGED
@@ -4,7 +4,7 @@ require 'mixlib/cli'
4
4
 
5
5
  module PKGWizard
6
6
 
7
- VERSION = '0.1.10'
7
+ VERSION = '0.1.12'
8
8
 
9
9
  class Distribution
10
10
  def self.detect
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pkg-wizard
3
3
  version: !ruby/object:Gem::Version
4
- hash: 15
4
+ hash: 3
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 1
9
- - 10
10
- version: 0.1.10
9
+ - 12
10
+ version: 0.1.12
11
11
  platform: ruby
12
12
  authors:
13
13
  - Sergio Rubio
@@ -15,11 +15,13 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2011-02-28 00:00:00 +01:00
18
+ date: 2011-03-01 00:00:00 +01:00
19
19
  default_executable: pkgwiz
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency
22
- requirement: &id001 !ruby/object:Gem::Requirement
22
+ type: :development
23
+ name: bundler
24
+ version_requirements: &id001 !ruby/object:Gem::Requirement
23
25
  none: false
24
26
  requirements:
25
27
  - - ~>
@@ -30,12 +32,12 @@ dependencies:
30
32
  - 0
31
33
  - 0
32
34
  version: 1.0.0
33
- name: bundler
35
+ requirement: *id001
34
36
  prerelease: false
35
- type: :development
36
- version_requirements: *id001
37
37
  - !ruby/object:Gem::Dependency
38
- requirement: &id002 !ruby/object:Gem::Requirement
38
+ type: :development
39
+ name: jeweler
40
+ version_requirements: &id002 !ruby/object:Gem::Requirement
39
41
  none: false
40
42
  requirements:
41
43
  - - ~>
@@ -46,12 +48,12 @@ dependencies:
46
48
  - 5
47
49
  - 2
48
50
  version: 1.5.2
49
- name: jeweler
51
+ requirement: *id002
50
52
  prerelease: false
51
- type: :development
52
- version_requirements: *id002
53
53
  - !ruby/object:Gem::Dependency
54
- requirement: &id003 !ruby/object:Gem::Requirement
54
+ type: :runtime
55
+ name: SystemTimer
56
+ version_requirements: &id003 !ruby/object:Gem::Requirement
55
57
  none: false
56
58
  requirements:
57
59
  - - ">="
@@ -60,12 +62,12 @@ dependencies:
60
62
  segments:
61
63
  - 0
62
64
  version: "0"
63
- name: SystemTimer
65
+ requirement: *id003
64
66
  prerelease: false
65
- type: :runtime
66
- version_requirements: *id003
67
67
  - !ruby/object:Gem::Dependency
68
- requirement: &id004 !ruby/object:Gem::Requirement
68
+ type: :runtime
69
+ name: resque
70
+ version_requirements: &id004 !ruby/object:Gem::Requirement
69
71
  none: false
70
72
  requirements:
71
73
  - - ">="
@@ -74,12 +76,12 @@ dependencies:
74
76
  segments:
75
77
  - 0
76
78
  version: "0"
77
- name: resque
79
+ requirement: *id004
78
80
  prerelease: false
79
- type: :runtime
80
- version_requirements: *id004
81
81
  - !ruby/object:Gem::Dependency
82
- requirement: &id005 !ruby/object:Gem::Requirement
82
+ type: :runtime
83
+ name: git
84
+ version_requirements: &id005 !ruby/object:Gem::Requirement
83
85
  none: false
84
86
  requirements:
85
87
  - - ">="
@@ -88,12 +90,12 @@ dependencies:
88
90
  segments:
89
91
  - 0
90
92
  version: "0"
91
- name: git
93
+ requirement: *id005
92
94
  prerelease: false
93
- type: :runtime
94
- version_requirements: *id005
95
95
  - !ruby/object:Gem::Dependency
96
- requirement: &id006 !ruby/object:Gem::Requirement
96
+ type: :runtime
97
+ name: sinatra
98
+ version_requirements: &id006 !ruby/object:Gem::Requirement
97
99
  none: false
98
100
  requirements:
99
101
  - - ">="
@@ -102,12 +104,12 @@ dependencies:
102
104
  segments:
103
105
  - 0
104
106
  version: "0"
105
- name: sinatra
107
+ requirement: *id006
106
108
  prerelease: false
107
- type: :runtime
108
- version_requirements: *id006
109
109
  - !ruby/object:Gem::Dependency
110
- requirement: &id007 !ruby/object:Gem::Requirement
110
+ type: :runtime
111
+ name: thin
112
+ version_requirements: &id007 !ruby/object:Gem::Requirement
111
113
  none: false
112
114
  requirements:
113
115
  - - ">="
@@ -116,12 +118,12 @@ dependencies:
116
118
  segments:
117
119
  - 0
118
120
  version: "0"
119
- name: thin
121
+ requirement: *id007
120
122
  prerelease: false
121
- type: :runtime
122
- version_requirements: *id007
123
123
  - !ruby/object:Gem::Dependency
124
- requirement: &id008 !ruby/object:Gem::Requirement
124
+ type: :runtime
125
+ name: rufus-scheduler
126
+ version_requirements: &id008 !ruby/object:Gem::Requirement
125
127
  none: false
126
128
  requirements:
127
129
  - - ">="
@@ -130,12 +132,12 @@ dependencies:
130
132
  segments:
131
133
  - 0
132
134
  version: "0"
133
- name: rufus-scheduler
135
+ requirement: *id008
134
136
  prerelease: false
135
- type: :runtime
136
- version_requirements: *id008
137
137
  - !ruby/object:Gem::Dependency
138
- requirement: &id009 !ruby/object:Gem::Requirement
138
+ type: :runtime
139
+ name: term-ansicolor
140
+ version_requirements: &id009 !ruby/object:Gem::Requirement
139
141
  none: false
140
142
  requirements:
141
143
  - - ">="
@@ -144,12 +146,12 @@ dependencies:
144
146
  segments:
145
147
  - 0
146
148
  version: "0"
147
- name: term-ansicolor
149
+ requirement: *id009
148
150
  prerelease: false
149
- type: :runtime
150
- version_requirements: *id009
151
151
  - !ruby/object:Gem::Dependency
152
- requirement: &id010 !ruby/object:Gem::Requirement
152
+ type: :runtime
153
+ name: mixlib-cli
154
+ version_requirements: &id010 !ruby/object:Gem::Requirement
153
155
  none: false
154
156
  requirements:
155
157
  - - ">="
@@ -158,10 +160,8 @@ dependencies:
158
160
  segments:
159
161
  - 0
160
162
  version: "0"
161
- name: mixlib-cli
163
+ requirement: *id010
162
164
  prerelease: false
163
- type: :runtime
164
- version_requirements: *id010
165
165
  description: Tools to manage,create and build distribution packages
166
166
  email: rubiojr@frameos.org
167
167
  executables:
@@ -177,7 +177,6 @@ files:
177
177
  - LICENSE.txt
178
178
  - README.rdoc
179
179
  - Rakefile
180
- - VERSION
181
180
  - bin/pkgwiz
182
181
  - lib/pkg-wizard.rb
183
182
  - lib/pkg-wizard/command.rb
data/VERSION DELETED
@@ -1 +0,0 @@
1
- 0.1.10