brewgem 0.0.7 → 0.0.8
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.
- checksums.yaml +4 -4
- data/config/templates/formula.rb.erb +12 -7
- data/lib/brewgem/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: f41e54a607dcb2da6aab6e00ce10bcde7ae2dbdc
|
|
4
|
+
data.tar.gz: 6ba8542ce8bf65ca4c2bc119716cb0e3b4ef1f72
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 29f94ffff7462b3c45e6f39595f2984a342d4fa1f6964b0798c8c4cbde7bd0ca726c095049efa5a2b4134c56ff7c3507d4468ce6de348ac532afd10f00a1309a
|
|
7
|
+
data.tar.gz: 00617df965d9d8c2624c9c0735b903e4cd838a8f948842d02f5d67b1835b40678343097ddb03b1762785c1ba24b2d3c5d58c5f94b879c6b0842c68904b48118e
|
|
@@ -5,11 +5,7 @@ class RubyGemsDownloadStrategy < AbstractDownloadStrategy
|
|
|
5
5
|
def fetch
|
|
6
6
|
ohai "Fetching #{name} from gem source"
|
|
7
7
|
HOMEBREW_CACHE.cd do
|
|
8
|
-
|
|
9
|
-
system "cp", "<%= local_path %>", "."
|
|
10
|
-
<% else %>
|
|
11
|
-
system "gem", "fetch", name, "--version", resource.version
|
|
12
|
-
<% end %>
|
|
8
|
+
system "gem", "fetch", name, "--version", resource.version
|
|
13
9
|
end
|
|
14
10
|
end
|
|
15
11
|
|
|
@@ -22,9 +18,18 @@ class RubyGemsDownloadStrategy < AbstractDownloadStrategy
|
|
|
22
18
|
end
|
|
23
19
|
end
|
|
24
20
|
|
|
21
|
+
class LocalGemDownloadStrategy < AbstractDownloadStrategy
|
|
22
|
+
def cached_location
|
|
23
|
+
Pathname.new('<%= local_path %>')
|
|
24
|
+
end
|
|
25
|
+
end
|
|
26
|
+
|
|
25
27
|
class <%= klass %> < Formula
|
|
26
|
-
url "<%= name %>", :using => RubyGemsDownloadStrategy
|
|
28
|
+
url "<%= name %>", :using => <%= local_path ? 'LocalGemDownloadStrategy' : 'RubyGemsDownloadStrategy' %>
|
|
27
29
|
version "<%= version %>"
|
|
30
|
+
<% if local_path %>
|
|
31
|
+
sha256 '<%= require 'digest'; Digest::SHA256.hexdigest(File.read(local_path)) %>'
|
|
32
|
+
<% end %>
|
|
28
33
|
|
|
29
34
|
def install
|
|
30
35
|
# Copy user's RubyGems config to temporary build home.
|
|
@@ -38,7 +43,7 @@ class <%= klass %> < Formula
|
|
|
38
43
|
# they might not be there if, say, we change to a different rvm gemset
|
|
39
44
|
ENV['GEM_HOME']="#{prefix}"
|
|
40
45
|
ENV['GEM_PATH']="#{prefix}"
|
|
41
|
-
system "gem", "install",
|
|
46
|
+
system "gem", "install", cached_download,
|
|
42
47
|
"--no-ri",
|
|
43
48
|
"--no-rdoc",
|
|
44
49
|
"--no-wrapper",
|
data/lib/brewgem/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: brewgem
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.0.
|
|
4
|
+
version: 0.0.8
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Joshua Peek
|
|
@@ -10,7 +10,7 @@ authors:
|
|
|
10
10
|
autorequire:
|
|
11
11
|
bindir: bin
|
|
12
12
|
cert_chain: []
|
|
13
|
-
date: 2016-
|
|
13
|
+
date: 2016-04-23 00:00:00.000000000 Z
|
|
14
14
|
dependencies:
|
|
15
15
|
- !ruby/object:Gem::Dependency
|
|
16
16
|
name: thor
|