homebrew_automation 0.1.4 → 0.1.5
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/lib/homebrew_automation/bottle.rb +11 -10
- data/lib/homebrew_automation/tap.rb +7 -6
- data/lib/homebrew_automation/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 9a3d541470864fdabac7601c9b4bca62c97f3b8a94f1af65d8dd36ab5bdd93d9
|
4
|
+
data.tar.gz: 23d0c6a2f2e625ace46a36bbdf18b13cd43611e66bf52655ea098208bf5d1dc0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 175915af38029378ecdc8b78fd463eb55e14e34d6d18222479f2feca5883c8f6f46341a68bba2ab44125b16121ec38392e0caaae973c45b32e86622dc69dea76
|
7
|
+
data.tar.gz: 362510628786c45559de477492efb7857ada4b3bd6b6973733c662b5307f0e550a2f515c87f80b2cde57a2cbc65c13fe5dde16a02fdc844c225aabb16aeb0871
|
@@ -33,11 +33,11 @@ module HomebrewAutomation
|
|
33
33
|
# @raise [StandardError]
|
34
34
|
# @return [nil]
|
35
35
|
def build
|
36
|
-
|
36
|
+
complain unless system 'brew', 'tap', tmp_tap_name, @tap_url
|
37
37
|
maybe_keep_tmp = @keep_tmp ? ['--keep-tmp'] : []
|
38
38
|
install_cmd = ['brew', 'install', '--verbose'] + maybe_keep_tmp + ['--build-bottle', fully_qualified_formula_name]
|
39
|
-
|
40
|
-
|
39
|
+
complain unless system(*install_cmd)
|
40
|
+
complain unless system 'brew', 'bottle', '--verbose', '--json', '--no-rebuild', fully_qualified_formula_name
|
41
41
|
end
|
42
42
|
|
43
43
|
# Read and analyse metadata JSON file
|
@@ -49,11 +49,11 @@ module HomebrewAutomation
|
|
49
49
|
return locate_tarball
|
50
50
|
end
|
51
51
|
json = JSON.parse(File.read(json_filename))
|
52
|
-
focus = json ||
|
53
|
-
focus = focus[json.keys.first] ||
|
54
|
-
focus = focus['bottle'] ||
|
55
|
-
focus = focus['tags'] ||
|
56
|
-
focus = focus[@os_name] ||
|
52
|
+
focus = json || complain
|
53
|
+
focus = focus[json.keys.first] || complain
|
54
|
+
focus = focus['bottle'] || complain
|
55
|
+
focus = focus['tags'] || complain
|
56
|
+
focus = focus[@os_name] || complain
|
57
57
|
@minus_minus, @filename = focus['local_filename'], focus['filename']
|
58
58
|
end
|
59
59
|
|
@@ -95,8 +95,9 @@ module HomebrewAutomation
|
|
95
95
|
tmp_tap_name + '/' + @formula_name
|
96
96
|
end
|
97
97
|
|
98
|
-
def
|
99
|
-
|
98
|
+
def complain
|
99
|
+
puts "HEY! Something has gone wrong and I need to complain. Stacktrace follows:"
|
100
|
+
puts caller
|
100
101
|
end
|
101
102
|
|
102
103
|
end
|
@@ -99,30 +99,31 @@ module HomebrewAutomation
|
|
99
99
|
# @param msg [String] Git commit message
|
100
100
|
# @raise [StandardError]
|
101
101
|
def git_commit_am(msg)
|
102
|
-
|
102
|
+
complain unless system "git", "commit", "-am", msg
|
103
103
|
end
|
104
104
|
|
105
105
|
# Just +git push+
|
106
106
|
#
|
107
107
|
# @raise [StandardError]
|
108
108
|
def git_push
|
109
|
-
|
109
|
+
complain unless system "git", "push"
|
110
110
|
end
|
111
111
|
|
112
112
|
# @raise [StandardError]
|
113
113
|
def _git_clone
|
114
|
-
|
114
|
+
complain unless system "git", "clone", @url
|
115
115
|
end
|
116
116
|
|
117
117
|
# @raise [StandardError]
|
118
118
|
def _remove_git_submodule
|
119
|
-
|
119
|
+
complain unless system "rm", "-rf", @repo
|
120
120
|
end
|
121
121
|
|
122
122
|
private
|
123
123
|
|
124
|
-
def
|
125
|
-
|
124
|
+
def complain
|
125
|
+
puts "HEY! Something has gone wrong and I need to complain. Stacktrace follows:"
|
126
|
+
puts caller
|
126
127
|
end
|
127
128
|
|
128
129
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: homebrew_automation
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- easoncxz
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-09-
|
11
|
+
date: 2019-09-30 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rspec
|