fpm 0.3.6 → 0.3.7

Sign up to get free protection for your applications and to get access to all the features.
data/lib/fpm/builder.rb CHANGED
@@ -201,10 +201,9 @@ class FPM::Builder
201
201
 
202
202
  private
203
203
  def checksum(paths)
204
- md5sums = []
205
- paths.each do |path|
204
+ paths.collect do |path|
206
205
  next if !File.exists?(path)
207
- md5sums += %x{find #{path} -type f -print0 | xargs -0 md5sum}.split("\n")
208
- end
206
+ %x{find #{path} -type f -printf %P\\\\0 | xargs -0 md5sum}.split("\n")
207
+ end.flatten
209
208
  end # def checksum
210
209
  end
@@ -47,7 +47,11 @@ class FPM::Source::Python < FPM::Source
47
47
  want_pkg = "#{package}==#{version}"
48
48
  end
49
49
 
50
- system(self[:settings][:easy_install], "--editable", "--build-directory", @tmpdir, want_pkg)
50
+ return_value = system(self[:settings][:easy_install], "--editable", "--build-directory", @tmpdir, want_pkg)
51
+
52
+ if return_value.nil?
53
+ raise "The execution of #{self[:settings][:easy_install]} failed"
54
+ end
51
55
 
52
56
  # easy_install will put stuff in @tmpdir/packagename/, flatten that.
53
57
  # That is, we want @tmpdir/setup.py, and start with
data/templates/deb.erb CHANGED
@@ -21,9 +21,8 @@ Section: <%= category or "unknown" %>
21
21
  Priority: extra
22
22
  Homepage: <%= url or "http://nourlgiven.example.com/" %>
23
23
  <% lines = (description or "no description given").split("\n") -%>
24
- <% firstline = lines.first -%>
25
- <% remainder = lines[1..-1] -%>
24
+ <% firstline, *remainder = lines -%>
26
25
  Description: <%= firstline %>
27
- <% if !remainder.nil? -%>
26
+ <% if remainder.any? -%>
28
27
  <%= remainder.collect { |l| l =~ /^ *$/ ? " ." : " #{l}" }.join("\n") %>
29
28
  <% end -%>
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fpm
3
3
  version: !ruby/object:Gem::Version
4
- hash: 31
4
+ hash: 29
5
5
  prerelease:
6
6
  segments:
7
7
  - 0
8
8
  - 3
9
- - 6
10
- version: 0.3.6
9
+ - 7
10
+ version: 0.3.7
11
11
  platform: ruby
12
12
  authors:
13
13
  - Jordan Sissel
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2011-07-08 00:00:00 -07:00
18
+ date: 2011-07-11 00:00:00 -07:00
19
19
  default_executable:
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency