fpm 0.3.2 → 0.3.3
Sign up to get free protection for your applications and to get access to all the features.
data/lib/fpm/package.rb
CHANGED
data/lib/fpm/source/gem.rb
CHANGED
@@ -15,7 +15,7 @@ class FPM::Source::Gem < FPM::Source
|
|
15
15
|
def get_source(params)
|
16
16
|
gem = @paths.first
|
17
17
|
looks_like_name_re = /^[A-Za-z0-9_-]+$/
|
18
|
-
if !File.exists?(gem)
|
18
|
+
if !File.exists?(gem)
|
19
19
|
if gem =~ looks_like_name_re
|
20
20
|
download(gem, params[:version])
|
21
21
|
else
|
@@ -37,12 +37,12 @@ class FPM::Source::Gem < FPM::Source
|
|
37
37
|
dep = ::Gem::Dependency.new gem_name, version
|
38
38
|
# How to handle prerelease? Some extra magic options?
|
39
39
|
#dep.prerelease = options[:prerelease]
|
40
|
-
|
40
|
+
|
41
41
|
if ::Gem::SpecFetcher.fetcher.respond_to?(:fetch_with_errors)
|
42
42
|
specs_and_sources, errors =
|
43
43
|
::Gem::SpecFetcher.fetcher.fetch_with_errors(dep, true, true, false)
|
44
44
|
else
|
45
|
-
specs_and_sources =
|
45
|
+
specs_and_sources =
|
46
46
|
::Gem::SpecFetcher.fetcher.fetch(dep, true)
|
47
47
|
errors = "???"
|
48
48
|
end
|
@@ -120,13 +120,15 @@ class FPM::Source::Gem < FPM::Source
|
|
120
120
|
args = ["gem", "install", "--quiet", "--no-ri", "--no-rdoc",
|
121
121
|
"--install-dir", installdir, "--ignore-dependencies"]
|
122
122
|
if self[:settings][:bin_path]
|
123
|
-
|
123
|
+
tmp_bin_path = File.join(tmpdir, self[:settings][:bin_path])
|
124
|
+
args += ["--bindir", tmp_bin_path]
|
124
125
|
@paths << self[:settings][:bin_path]
|
126
|
+
FileUtils.mkdir_p(tmp_bin_path) # Fixes #27
|
125
127
|
end
|
126
128
|
|
127
129
|
args << gem
|
128
130
|
system(*args)
|
129
|
-
|
131
|
+
|
130
132
|
# make paths relative (/foo becomes ./foo)
|
131
133
|
tar(tar_path, @paths.collect {|p| ".#{p}"}, tmpdir)
|
132
134
|
FileUtils.rm_r(tmpdir)
|
Binary file
|
Binary file
|
data/lib/fpm/target/puppet.rb
CHANGED
@@ -3,7 +3,7 @@ require "fpm/namespace"
|
|
3
3
|
require "fpm/package"
|
4
4
|
require "fpm/errors"
|
5
5
|
require "etc"
|
6
|
-
require "
|
6
|
+
require "fileutils"
|
7
7
|
|
8
8
|
# TODO(sissel): Add dependency checking support.
|
9
9
|
# IIRC this has to be done as a 'checkinstall' step.
|
@@ -77,7 +77,7 @@ class FPM::Target::Puppet < FPM::Package
|
|
77
77
|
if File.directory?(path)
|
78
78
|
::Dir.mkdir(File.join(params[:output], path))
|
79
79
|
else
|
80
|
-
|
80
|
+
FileUtils.cp(path, File.join(params[:output], path))
|
81
81
|
end
|
82
82
|
end
|
83
83
|
end # def build!
|
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:
|
4
|
+
hash: 21
|
5
5
|
prerelease:
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 3
|
9
|
-
-
|
10
|
-
version: 0.3.
|
9
|
+
- 3
|
10
|
+
version: 0.3.3
|
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-06-
|
18
|
+
date: 2011-06-24 00:00:00 -07:00
|
19
19
|
default_executable:
|
20
20
|
dependencies:
|
21
21
|
- !ruby/object:Gem::Dependency
|
@@ -60,6 +60,8 @@ files:
|
|
60
60
|
- lib/fpm/source/rpm.rb
|
61
61
|
- lib/fpm/source/dir.rb
|
62
62
|
- lib/fpm/source/tar.rb
|
63
|
+
- lib/fpm/source/pyfpm/__init__.pyc
|
64
|
+
- lib/fpm/source/pyfpm/get_metadata.pyc
|
63
65
|
- lib/fpm/source/pyfpm/__init__.py
|
64
66
|
- lib/fpm/source/pyfpm/get_metadata.py
|
65
67
|
- lib/rpm/tag.rb
|