summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjkoan <jkoan@users.noreply.github.com>2021-10-05 04:03:19 +0200
committerGitHub <noreply@github.com>2021-10-04 19:03:19 -0700
commit1ed7f1b24a775603d969c0995e3acc8ea4ba164b (patch)
tree5fb1b8a293054feb315b2ab890412326fe3d2a4f
parent993d50ebb10e4884d4ac3c48c11ae6ab1ae7c220 (diff)
downloadnavit-1ed7f1b24a775603d969c0995e3acc8ea4ba164b.tar.gz
delete:build:Delete old tooling from android (now fastlane is used) (#1161)
-rw-r--r--scripts/basic_upload_apks.py81
-rwxr-xr-xscripts/build.sh14
-rwxr-xr-xscripts/publish.sh35
3 files changed, 0 insertions, 130 deletions
diff --git a/scripts/basic_upload_apks.py b/scripts/basic_upload_apks.py
deleted file mode 100644
index 1bd911f15..000000000
--- a/scripts/basic_upload_apks.py
+++ /dev/null
@@ -1,81 +0,0 @@
-#!/usr/bin/python
-#
-# Copyright 2014 Google Inc. All Rights Reserved.
-#
-# Licensed under the Apache License, Version 2.0 (the 'License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-"""Uploads an apk to the beta track."""
-
-import argparse
-import sys
-from apiclient import sample_tools
-from oauth2client import client
-
-TRACK = 'beta' # Can be 'alpha', beta', 'production' or 'rollout'
-
-# Declare command-line flags.
-argparser = argparse.ArgumentParser(add_help=False)
-argparser.add_argument('package_name',
- help='The package name. Example: com.android.sample')
-argparser.add_argument('apk_file',
- nargs='?',
- default='test.apk',
- help='The path to the APK file to upload.')
-
-
-def main(argv):
- # Authenticate and construct service.
- service, flags = sample_tools.init(
- argv,
- 'androidpublisher',
- 'v2',
- __doc__,
- __file__, parents=[argparser],
- scope='https://www.googleapis.com/auth/androidpublisher')
-
- # Process flags and read their values.
- package_name = flags.package_name
- apk_file = flags.apk_file
-
- try:
- edit_request = service.edits().insert(body={}, packageName=package_name)
- result = edit_request.execute()
- edit_id = result['id']
-
- apk_response = service.edits().apks().upload(
- editId=edit_id,
- packageName=package_name,
- media_body=apk_file).execute()
-
- print 'Version code %d has been uploaded' % apk_response['versionCode']
-
- track_response = service.edits().tracks().update(
- editId=edit_id,
- track=TRACK,
- packageName=package_name,
- body={u'versionCodes': [apk_response['versionCode']]}).execute()
-
- print 'Track %s is set for version code(s) %s' % (
- track_response['track'], str(track_response['versionCodes']))
-
- commit_request = service.edits().commit(
- editId=edit_id, packageName=package_name).execute()
-
- print 'Edit "%s" has been committed' % (commit_request['id'])
-
- except client.AccessTokenRefreshError:
- print ('The credentials have been revoked or expired, please re-run the '
- 'application to re-authorize')
-
-if __name__ == '__main__':
- main(sys.argv)
diff --git a/scripts/build.sh b/scripts/build.sh
deleted file mode 100755
index 536ab7781..000000000
--- a/scripts/build.sh
+++ /dev/null
@@ -1,14 +0,0 @@
-set -e
-
-echo "$# build script (s) to run"
-
-for i in $(seq 1 $#); do
- eval s=\$$i
- echo "Starting build script #$i : $s"
- if [ ! -z $CIRCLE_ARTIFACTS ]; then
- set -o pipefail
- bash -e $s 2>&1 | tee $CIRCLE_ARTIFACTS/${i}.log
- else
- bash -e $s
- fi
-done
diff --git a/scripts/publish.sh b/scripts/publish.sh
deleted file mode 100755
index 8b564eaa8..000000000
--- a/scripts/publish.sh
+++ /dev/null
@@ -1,35 +0,0 @@
-#!/usr/bin/env bash
-
-if [ -z $CI ];then
- echo "This Script needs to be run by CI"
-fi
-if [ -z $CIRCLECI ];then
- echo "This Script needs to be run on CircleCI"
-fi
-if [[ "${CIRCLE_PROJECT_USERNAME}" != "navit-gps" || "${CIRCLE_BRANCH}" != "trunk" ]]; then
- echo "Only trunk on navit-gps may upload to the Play Store"
- exit 0
-fi
-
-set -e
-
-ARCH="arm"
-BINPATH="android-arm/navit/android/bin"
-
-export PATH="/opt/android-sdk-linux/build-tools/25.0.1/":$PATH
-
-cd ~/
-git clone git@github.com:navit-gps/infrastructure-blackbox.git
-cd infrastructure-blackbox/keyrings/
-openssl aes-256-cbc -d -in keystore.gpg -k $KEY > ~/.keystore
-openssl aes-256-cbc -d -in client_secrets.gpg -k $KEY > /root/project/scripts/client_secrets.json
-openssl aes-256-cbc -d -in androidpublisher.gpg -k $KEY > /root/project/androidpublisher.dat
-cd ~/project
-
-pip install google-api-python-client
-
-jarsigner -verbose -sigalg SHA1withRSA -digestalg SHA1 -storepass $SP $BINPATH/navit-$CIRCLE_SHA1-${ARCH}-release-unsigned.apk $key_name
-
-zipalign 4 $BINPATH/navit-$CIRCLE_SHA1-${ARCH}-release-unsigned.apk $BINPATH/navit-$CIRCLE_SHA1-${ARCH}-release-signed.apk
-apksigner verify -v $BINPATH/navit-$CIRCLE_SHA1-${ARCH}-release-signed.apk
-python ~/project/scripts/basic_upload_apks.py org.navitproject.navit $BINPATH/navit-$CIRCLE_SHA1-${ARCH}-release-signed.apk --noauth_local_webserver