OLD | NEW |
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file |
2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
4 | 4 |
5 library update_homebrew; | 5 library update_homebrew; |
6 | 6 |
7 import 'dart:async'; | 7 import 'dart:async'; |
8 import 'dart:convert'; | 8 import 'dart:convert'; |
9 import 'dart:io'; | 9 import 'dart:io'; |
10 | 10 |
(...skipping 151 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
162 | 162 |
163 resource 'dartium' do | 163 resource 'dartium' do |
164 version '$stableVersion' | 164 version '$stableVersion' |
165 url '$urlBase/stable/release/${revisions['stable']}/$dartiumFile' | 165 url '$urlBase/stable/release/${revisions['stable']}/$dartiumFile' |
166 sha256 '${hashes['stable'][dartiumFile]}' | 166 sha256 '${hashes['stable'][dartiumFile]}' |
167 end | 167 end |
168 | 168 |
169 def install | 169 def install |
170 libexec.install Dir['*'] | 170 libexec.install Dir['*'] |
171 bin.install_symlink "#{libexec}/bin/dart" | 171 bin.install_symlink "#{libexec}/bin/dart" |
172 bin.write_exec_script Dir["#{libexec}/bin/{pub,docgen,dart?*}"] | 172 bin.write_exec_script Dir["#{libexec}/bin/{pub,dart?*}"] |
173 | 173 |
174 if build.with? 'dartium' | 174 if build.with? 'dartium' |
175 dartium_binary = 'Chromium.app/Contents/MacOS/Chromium' | 175 dartium_binary = 'Chromium.app/Contents/MacOS/Chromium' |
176 prefix.install resource('dartium') | 176 prefix.install resource('dartium') |
177 (bin+"dartium").write shim_script dartium_binary | 177 (bin+"dartium").write shim_script dartium_binary |
178 end | 178 end |
179 | 179 |
180 if build.with? 'content-shell' | 180 if build.with? 'content-shell' |
181 content_shell_binary = 'Content Shell.app/Contents/MacOS/Content Shell' | 181 content_shell_binary = 'Content Shell.app/Contents/MacOS/Content Shell' |
182 prefix.install resource('content_shell') | 182 prefix.install resource('content_shell') |
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
260 | 260 |
261 await runGit(['push']); | 261 await runGit(['push']); |
262 } finally { | 262 } finally { |
263 await tempDir.delete(recursive: true); | 263 await tempDir.delete(recursive: true); |
264 } | 264 } |
265 }, onError: (error, chain) { | 265 }, onError: (error, chain) { |
266 print(error); | 266 print(error); |
267 print(chain.terse); | 267 print(chain.terse); |
268 }); | 268 }); |
269 } | 269 } |
OLD | NEW |