Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(79)

Side by Side Diff: sky/tools/big_red_button.py

Issue 1214193007: Add big_red_button script so that others can deploy (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 # Roll versions script:
2 # /src/mojo/src/sky/apk/demo/AndroidManifest.xml version and string.
3 # Update versions of pub packages:
4
5 # Make a commit, upload it, land it.
6
7 import os
8 import subprocess
9
10 def run(cwd, args):
11 print 'RUNNING:', ' '.join(args), 'IN:', cwd
12 subprocess.check_call(args, cwd=cwd)
13
14 # Input paths:
15 # FIXME: These could be args?
16 MOJO_ROOT = '/src/mojo/src'
17 SKY_SDK_ROOT = '/src/sky_sdk'
18 DEMO_SITE_ROOT = '/src/domokit.github.io'
19
20 # Derived paths:
21 DART_SDK_ROOT = os.path.join(MOJO_ROOT, 'third_party/dart-sdk/dart-sdk')
22 PUB_PATH = os.path.join(DART_SDK_ROOT, 'bin/pub')
23 PACKAGES_ROOT = os.path.join(SKY_SDK_ROOT, 'packages')
24
25
26 run(MOJO_ROOT, ['git', 'pull', '--rebase'])
27 run(MOJO_ROOT, ['gclient', 'sync'])
28 run(MOJO_ROOT, ['mojo/tools/mojob.py', 'gn', '--android', '--release'])
29 run(MOJO_ROOT, ['mojo/tools/mojob.py', 'build', '--android', '--release'])
30 # Run tests?
31
32 run(SKY_SDK_ROOT, ['git', 'reset', '--hard', 'origin/master'])
33 run(MOJO_ROOT, [
34 'sky/tools/deploy_sdk.py',
35 '--non-interactive',
36 '--commit',
37 SKY_SDK_ROOT
38 ])
39 # tag for version?
40
41 run(DEMO_SITE_ROOT, ['git', 'reset', '--hard', 'origin/master'])
42 run(MOJO_ROOT, ['mojo/tools/deploy_domokit_site.py', DEMO_SITE_ROOT])
43 # tag for version?
44
45 for package in os.listdir(PACKAGES_ROOT):
46 package_path = os.path.join(PACKAGES_ROOT, package)
47 if not os.path.isdir(package_path):
48 continue
49 run(package_path, [PUB_PATH, 'publish', '--force'])
50
51 run(SKY_SDK_ROOT, ['git', 'push'])
52 run(DEMO_SITE_ROOT, ['git', 'push'])
53
54 # http://stackoverflow.com/questions/14665518/api-to-automatically-upload-apk-to -google-play
55 # https://developers.google.com/resources/api-libraries/documentation/androidpub lisher/v2/python/latest/androidpublisher_v2.edits.apks.html
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698