rubinjam 0.4.0 → 0.4.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 94a233c7365a6647d6ad02fa0afab140e2d6ffe2
4
- data.tar.gz: 2a09dd1b089bb99a67f36d2eebc9288fbb33ba0d
3
+ metadata.gz: 8dfbf9e2a278c90af3da8ede1a9443b665595a51
4
+ data.tar.gz: 4637b949e8ca3fae746fdd64ae89117403175b5f
5
5
  SHA512:
6
- metadata.gz: 641e71bbd866756510e9ff0ee898477212fe490dc7f0e3bce037fac310aba7d7afe4f63fb25c94ec6df88fea87043b03434d663b81fa284d14d8032c82afe5e2
7
- data.tar.gz: 2476f27e34b07142d483de3a5359372c31c0e322edc9525604255c364519cc37bf06b23eabe616a2ad0e3b2338ed14a1b24e1ec0fa0e981cf6bd4e58d57eff54
6
+ metadata.gz: 09119a44c5e0b820dd9c6297b995ba3e8a9a1f5e48a991cefba1aa89b7b4f9fdfb1b9ab32c0420ef12cee4997380b05c7fe3284bd87d86140b63b795d4ba8908
7
+ data.tar.gz: 2af14192ea592ceb4144c7fab29c3a5b374fe58cf3df9f0d71ff8ed5c4839dd18da4880ff20046d313b0a6c97be448a825bff411ef4222ebf76b4010b43e39eb
@@ -1,3 +1,3 @@
1
1
  module Rubinjam
2
- VERSION = "0.4.0"
2
+ VERSION = "0.4.1"
3
3
  end
data/lib/rubinjam.rb CHANGED
@@ -3,6 +3,8 @@ require "bundler"
3
3
  require "rubinjam/version"
4
4
 
5
5
  module Rubinjam
6
+ HEADER = '#!/usr/bin/env ruby'.freeze
7
+
6
8
  class << self
7
9
  def pack(dir)
8
10
  Dir.chdir(dir) do
@@ -23,12 +25,12 @@ module Rubinjam
23
25
  # fetch
24
26
  command = "gem fetch #{Shellwords.escape(gem)}"
25
27
  command << " -v" << version if version
26
- IO.popen(command).read
28
+ sh(command)
27
29
 
28
30
  # load spec
29
31
  gem_ball = Dir["*.gem"].first
30
32
  spec = Gem::Package.new(gem_ball).spec.to_ruby
31
- IO.popen("gem unpack #{gem_ball}").read
33
+ sh("gem unpack #{gem_ball}")
32
34
 
33
35
  # bundle
34
36
  Dir.chdir(gem_ball.sub(".gem", "")) do
@@ -57,9 +59,9 @@ module Rubinjam
57
59
  source "https://rubygems.org"
58
60
  gemspec
59
61
  RUBY
62
+
60
63
  sh("rm -f Gemfile.lock")
61
- bundle = "bundle install --quiet --path bundle"
62
- sh("#{bundle} --local || #{bundle}")
64
+ sh("BUNDLE_IGNORE_CONFIG=1 bundle install --quiet --path bundle") # heroku has a --deployment config -> ignore it
63
65
  paths = sh("bundle exec ruby -e 'puts $LOAD_PATH'").split("\n")
64
66
  paths = paths.grep(%r{/gems/}).reject { |r| r =~ %r{/gems/bundler-\d} }
65
67
  libs_from_paths(paths)
@@ -88,7 +90,7 @@ module Rubinjam
88
90
 
89
91
  def environment
90
92
  <<-RUBY.gsub(/^ /, "")
91
- #!/usr/bin/env ruby
93
+ #{HEADER}
92
94
  # generated by rubinjam v#{VERSION} -- https://github.com/grosser/rubinjam
93
95
  module Rubinjam
94
96
  LIBRARIES = {
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rubinjam
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.0
4
+ version: 0.4.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Michael Grosser
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-12-20 00:00:00.000000000 Z
11
+ date: 2014-12-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler