Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test setup step #1245

Open
wants to merge 35 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
35 commits
Select commit Hold shift + click to select a range
eaec3a8
test setup step
jessopb Nov 25, 2022
6ef7d04
add push condition for action
jessopb Nov 25, 2022
7a7506e
verify pwd
jessopb Nov 25, 2022
74b5435
verify ls al
jessopb Nov 26, 2022
a5cbf14
typo ls
jessopb Nov 26, 2022
c808764
try gsr
jessopb Nov 26, 2022
0ef598c
try git-secret
jessopb Nov 26, 2022
7228173
try git init
jessopb Nov 26, 2022
c51f324
troubleshooting
jessopb Nov 26, 2022
b6a2eb2
try git secret init
jessopb Nov 26, 2022
8ccfb57
try init again
jessopb Nov 26, 2022
9480579
try
jessopb Nov 26, 2022
e4a708f
g s r
jessopb Nov 26, 2022
681ae1c
git rev-parse inside?
jessopb Nov 26, 2022
2de5f7d
try global safe hack
jessopb Nov 26, 2022
d6eebb5
check git version
jessopb Nov 26, 2022
130412b
upgrade git
jessopb Nov 26, 2022
1b34352
apt-get
jessopb Nov 26, 2022
4b96cfd
fix apt scripts
jessopb Nov 26, 2022
8943643
git ownership workaround
jessopb Nov 26, 2022
11b810f
build
jessopb Nov 26, 2022
ab498cc
github_workspace
jessopb Nov 26, 2022
2ba7647
troubleshoot build
jessopb Nov 26, 2022
753499f
try newer exoplayer
jessopb Nov 26, 2022
576c092
try updated impls
jessopb Nov 26, 2022
5e0548c
move export ANDROID_SDK_ROOT up
jessopb Nov 26, 2022
73eab49
gradlew stacktrace
jessopb Nov 26, 2022
d5d6331
troubleshoot...
jessopb Nov 26, 2022
21dc2b2
test github env android root
jessopb Nov 26, 2022
da09cc2
try odysee android script
jessopb Nov 26, 2022
de1e4c7
chmod gradlew
jessopb Nov 26, 2022
c091092
fix flexbox?
jessopb Nov 26, 2022
7bfd9be
flexbox snapshot?
jessopb Nov 26, 2022
b87fcee
typo
jessopb Nov 26, 2022
89237a3
flexbox 3.0.0
jessopb Nov 26, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
106 changes: 106 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -1 +1,107 @@
name: Publish APK

on:
pull_request:
branches: [test-deploy]
push:
branches: [test-deploy]

jobs:
# build:
# runs-on: ubuntu-latest
# container: lbry/android-base:platform-28
# steps:
# - name: update git # container git is too old
# run: |
# apt-get install -y software-properties-common
# apt-get update
# add-apt-repository -y ppa:git-core/ppa
# apt-get update
# apt-get install -y git
# - name: work around for permission issue # git doesn't trust user that owns the checkout
# run: |
# git config --global --add safe.directory /__w/lbry-android/lbry-android
# - name: checkout
# uses: actions/checkout@v3
# - name: hacky copy # docker image runs ~ as /root, but github actions uses ~=/github/home
# run: |
# cp -r /root/.buildozer ~/.buildozer/
# - name: setup
# run: |
# echo "$PGP_PRIVATE_KEY" | gpg --batch --import
# echo 'deb https://gitsecret.jfrog.io/artifactory/git-secret-deb git-secret main' >> /etc/apt/sources.list
# wget -qO - 'https://gitsecret.jfrog.io/artifactory/api/gpg/key/public' | apt-key add -
# apt-get -y update && apt-get -y install build-essential ca-certificates curl gpg-agent openjdk-8-jdk software-properties-common wget zipalign git-secret
# ls -al ..
# ls -al
# git rev-parse --is-inside-work-tree
# git secret reveal
# chmod u+x $GITHUB_WORKSPACE/gradlew
# export BUILD_VERSION=$($GITHUB_WORKSPACE/gradlew -p $GITHUB_WORKSPACE -q printVersionName --console=plain | tail -1)
# export PATH=/usr/bin:$PATH
# export ANDROID_SDK_ROOT=~/.buildozer/android/platform/android-sdk-23
# echo $ANDROID_SDK_ROOT
# echo "ANDROID_SDK_ROOT=$ANDROID_SDK_ROOT" >> $GITHUB_ENV
# echo "end of setup home:"
# echo $HOME
# env:
# PGP_PRIVATE_KEY: ${{ secrets.PGP_PRIVATE_KEY }}
# KEYSTORE_PASSWORD: ${{ secrets.KEYSTORE_PASSWORD }}
# - name: build
# run: |
# ls -al ~/
# chmod u+x ./release.sh
# ./release.sh
# cp bin/browser-$BUILD_VERSION-release__arm.apk /dev/null
# cp bin/browser-$BUILD_VERSION-release__arm64.apk /dev/null
# env:
# PGP_PRIVATE_KEY: ${{ secrets.PGP_PRIVATE_KEY }}
# KEYSTORE_PASSWORD: ${{ secrets.KEYSTORE_PASSWORD }}

# - name: Upload math result for job 1
# uses: actions/upload-artifact@v3
# with:
# name: homework
# path: math-homework.txt
build-release:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- uses: gradle/wrapper-validation-action@v1

- name: Create and checkout branch
# push events already checked out the branch
if: github.event_name == 'pull_request'
run: git checkout -B ${{ github.head_ref }}

- name: Set up JDK 11
uses: actions/setup-java@v3
with:
java-version: '11'
distribution: 'temurin'
cache: 'gradle'

- name: Reveal secrets
env:
PGP_PRIVATE_KEY: ${{ secrets.PGP_PRIVATE_KEY }}
run: |
sudo apt install git-secret gpg-agent
echo "$PGP_PRIVATE_KEY" | gpg --batch --import
git secret reveal
- name: Install NDK version 21.0.6113669
run: echo "y" | sudo ${ANDROID_HOME}/tools/bin/sdkmanager --install "ndk;21.0.6113669"

- name: Build
env:
KEYSTORE_PASSWORD: ${{ secrets.KEYSTORE_PASSWORD }}
run: |
sudo apt install zipalign apksigner
chmod +x gradlew
./release.sh
rm bin/*-unsigned.apk
- name: Upload APK
uses: actions/upload-artifact@v3
with:
name: app-release
path: bin/*.apk
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -67,3 +67,4 @@ app/twitter.properties
app/build
bin
app/debuglib
.vscode
16 changes: 8 additions & 8 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -103,20 +103,20 @@ dependencies {
implementation 'com.android.billingclient:billing:3.0.2'

implementation 'com.google.code.gson:gson:2.8.6'
implementation 'com.google.android.exoplayer:exoplayer-core:2.12.2'
implementation 'com.google.android.exoplayer:exoplayer-dash:2.12.2'
implementation 'com.google.android.exoplayer:exoplayer-ui:2.12.2'
implementation 'com.google.android.exoplayer:extension-cast:2.12.2'
implementation 'com.google.android.exoplayer:extension-mediasession:2.12.2'
implementation 'com.google.android.exoplayer:exoplayer-core:2.15.1'
implementation 'com.google.android.exoplayer:exoplayer-dash:2.15.1'
implementation 'com.google.android.exoplayer:exoplayer-ui:2.15.1'
implementation 'com.google.android.exoplayer:extension-cast:2.15.1'
implementation 'com.google.android.exoplayer:extension-mediasession:2.15.1'

implementation 'com.google.android:flexbox:2.0.1'
implementation 'com.google.android.flexbox:flexbox:3.0.0'

implementation 'com.hbb20:ccp:2.3.8'
implementation 'com.hbb20:ccp:2.4.7'

implementation 'com.github.chrisbanes:PhotoView:2.3.0'
implementation 'com.atlassian.commonmark:commonmark:0.14.0'

implementation 'com.arthenica:mobile-ffmpeg-full-gpl:4.3.1.LTS'
implementation 'com.arthenica:mobile-ffmpeg-full-gpl:4.4.LTS'

implementation 'commons-codec:commons-codec:1.15'
implementation 'org.bitcoinj:bitcoinj-tools:0.14.7'
Expand Down
5 changes: 4 additions & 1 deletion release.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
#!/bin/bash
./gradlew assembleRelease --console=plain
echo "release.sh"
echo $HOME
echo $ANDROID_SDK_ROOT
./gradlew assembleRelease --console=plain --stacktrace
version=$(./gradlew -q printVersionName --console=plain | tail -1)
mkdir -p bin/
rm -f bin/*
Expand Down