Deprecated QT-based UI for Cwtch: For the new Flutter UI go to: https://git.openprivacy.ca/cwtch.im/cwtch-ui https://cwtch.im
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
This repo is archived. You can view files and clone it, but cannot push or open issues/pull-requests.
 
 
 
 
 
 

222 lines
7.6 KiB

workspace:
base: /media/sf_GOPATH1/src/cwtch.im
path: ui
pipeline:
build-linux:
mem_limit: 3G
image: therecipe/qt:linux_static
when:
repo: cwtch.im/ui
branch: master
event: [ push, pull_request ]
environment:
- QT_DIR=/opt/Qt
- QT_DOCKER='true'
- QT_API=5.13.0
- GO111MODULE=on
commands:
- export PATH=$PATH:/home/user/work/bin:/media/sf_GOPATH1/bin
- apt-get -qq update && apt-get --no-install-recommends -qq -y install ca-certificates curl git openssh-client
- go mod download
- $QT_DIR/$QT_API/gcc_64/bin/lrelease ui.pro
- git fetch --tags
- export VERSION=`git describe --tags`
- export BUILDDATE=`date +%G-%m-%d-%H-%M`
- go mod vendor
- qtdeploy -ldflags "-X main.buildVer=$VERSION -X main.buildDate=$BUILDDATE" build linux
- cp README.md deploy/linux
- cp -R assets deploy/linux/
- export FILENAME=cwtch-linux-$BUILDDATE.tar.gz
- cd deploy
- mv linux cwtch
- tar -czf $FILENAME cwtch
- sha256sum $FILENAME > $FILENAME.sha256
- rm -r cwtch
build-android-arm-v7a:
mem_limit: 3G
image: therecipe/qt:android
secrets: [upload_jks_file,upload_jks_pass]
when:
repo: cwtch.im/ui
branch: master
event: push
environment:
- QT_DIR=/opt/Qt
- QT_DOCKER='true'
- QT_API=5.13.0
- ANDROID_NDK_DIR=/home/user/android-ndk-r18b
- ANDROID_SDK_DIR=/home/user/android-sdk-linux
- GO111MODULE=on
commands:
- export PATH=$PATH:/home/user/work/bin:/media/sf_GOPATH1/bin
- apt-get -qq update && apt-get --no-install-recommends -qq -y install ca-certificates curl git
- rm -r vendor/
- make clean
- echo "cwtch-upload" > android/jks_alias
- echo $UPLOAD_JKS_PASS > android/jks_pass
- echo $UPLOAD_JKS_FILE | tr -d '\n ' > android/ui.jks.b64
- base64 --decode android/ui.jks.b64 > android/ui.jks
- export GOARCH=arm
- go mod download
- export VERSION=`git describe --tags`
- export BUILDDATE=`date +%G-%m-%d-%H-%M`
- go mod vendor
- qtsetup generate android
- mv assets android/
- ANDROID_MODULES_INCLUDE="Core,Gui,Svg,QuickWidgets,Xml" qtdeploy -ldflags "-X main.buildVer=$VERSION -X main.buildDate=$BUILDDATE" build android
- mv android/assets assets
- cd deploy
- export FILENAME=cwtch-android-arm-v7a-$BUILDDATE.apk
- cp android/build-release-signed.apk $FILENAME
- sha256sum $FILENAME > $FILENAME.sha256
- rm -r android
build-android-arm64-v8a:
mem_limit: 3G
image: therecipe/qt:android
secrets: [upload_jks_file,upload_jks_pass]
when:
repo: cwtch.im/ui
branch: master
event: push
environment:
- QT_DIR=/opt/Qt
- QT_DOCKER='true'
- QT_API=5.13.0
- ANDROID_NDK_DIR=/home/user/android-ndk-r18b
- ANDROID_SDK_DIR=/home/user/android-sdk-linux
- GO111MODULE=on
commands:
- export PATH=$PATH:/home/user/work/bin:/media/sf_GOPATH1/bin
- apt-get -qq update && apt-get --no-install-recommends -qq -y install ca-certificates curl git
- rm -r vendor/
- make clean
- echo "cwtch-upload" > android/jks_alias
- echo $UPLOAD_JKS_PASS > android/jks_pass
- echo $UPLOAD_JKS_FILE | tr -d '\n ' > android/ui.jks.b64
- base64 --decode android/ui.jks.b64 > android/ui.jks
- export GOARCH=arm64
- perl -pe 's/versionCode="(\d+)"/"versionCode=\"" .($1+1)."\""/eg' android/AndroidManifest.xml > android/AndroidManifest.xml.inc
- rm android/AndroidManifest.xml
- mv android/AndroidManifest.xml.inc android/AndroidManifest.xml
- go mod download
- export VERSION=`git describe --tags`
- export BUILDDATE=`date +%G-%m-%d-%H-%M`
- go mod vendor
- qtsetup generate android
- mv assets android/
- ANDROID_MODULES_INCLUDE="Core,Gui,Svg,QuickWidgets,Xml" qtdeploy -ldflags "-X main.buildVer=$VERSION -X main.buildDate=$BUILDDATE" build android
- mv android/assets assets
- cd deploy
- export FILENAME=cwtch-android-arm64-v8a-$BUILDDATE.apk
- cp android/build-release-signed.apk $FILENAME
- sha256sum $FILENAME > $FILENAME.sha256
- rm -r android
build-windows:
mem_limit: 3G
image: therecipe/qt:windows_64_static
when:
repo: cwtch.im/ui
branch: [ master, windows_build ]
event: push
environment:
- QT_DIR=/opt/Qt
- QT_DOCKER='true'
- QT_API=5.13.0
- GO111MODULE=on
commands:
- export PATH=$PATH:/home/user/work/bin:/media/sf_GOPATH1/bin
- apt-get -qq update && apt-get --no-install-recommends -qq -y install ca-certificates curl git zip
- rm -r vendor || true
- make clean || true
- go mod download
- export VERSION=`git describe --tags`
- export BUILDDATE=`date +%G-%m-%d-%H-%M`
- go mod vendor
- export QT_DEBUG=true
- export CONSOLE=true
- export QT_DEBUG_QML=true
- qtdeploy -ldflags "-X main.buildVer=$VERSION -X main.buildDate=$BUILDDATE" build windows
- cp README.md deploy/windows
- cp -R assets deploy/windows/
- cp -r windows/* deploy/windows
- cd deploy
- mv windows cwtch
- export FILENAME=cwtch-windows-$BUILDDATE.zip
- zip -r $FILENAME cwtch
- sha256sum $FILENAME > $FILENAME.sha256
- mv cwtch windows
package-windows:
mem_limit: 3G
image: hp41/nsis:latest
when:
repo: cwtch.im/ui
branch: [ master, windows_build ]
event: push
environment:
commands:
- cp nsis/cwtch-installer.nsi deploy/
- cd deploy
- makensis -V3 cwtch-installer.nsi
- export BUILDDATE=`date +%G-%m-%d-%H-%M`
- export FILENAME=cwtch-installer-$BUILDDATE.exe
- mv cwtch-installer.exe $FILENAME
- sha256sum $FILENAME > $FILENAME.sha256
- rm cwtch-installer.nsi
- rm -r windows
deploy-buildfiles:
image: pivotaldata/concourse-ssh
secrets: [buildfiles_key]
when:
repo: cwtch.im/ui
branch: master
event: push
status: [ success ]
commands:
- apk add --no-cache git
- echo $BUILDFILES_KEY > ~/id_rsab64
- base64 -d ~/id_rsab64 > ~/id_rsa
- chmod 400 ~/id_rsa
- export DIR=`date +%G.%m.%d-%H.%M`-`git describe --tags`
- cd deploy
- mkdir $DIR
- mv cwtch* $DIR/
- scp -r -o StrictHostKeyChecking=no -i ~/id_rsa $DIR buildfiles@openprivacy.ca:/home/buildfiles/buildfiles/
deploy-windows-build:
image: pivotaldata/concourse-ssh
secrets: [buildfiles_key]
when:
repo: cwtch.im/ui
branch: windows_build
event: push
status: [ success ]
commands:
- apk add --no-cache git
- echo $BUILDFILES_KEY > ~/id_rsab64
- base64 -d ~/id_rsab64 > ~/id_rsa
- chmod 400 ~/id_rsa
- git fetch --tags
- export DIR=`date +%G.%m.%d-%H.%M`-`git describe --tags`
- cd deploy
- mkdir -p windows_build/$DIR
- mv cwtch* windows_build/$DIR/
- scp -r -o StrictHostKeyChecking=no -i ~/id_rsa windows_build buildfiles@openprivacy.ca:/home/buildfiles/buildfiles/
notify-email:
image: drillster/drone-email
host: build.openprivacy.ca
port: 25
skip_verify: true
from: drone@openprivacy.ca
when:
repo: cwtch.im/ui
branch: master
status: [ failure ]
notify-gogs:
image: openpriv/drone-gogs
when:
repo: cwtch.im/ui
branch: master
event: pull_request
status: [ success, changed, failure ]
secrets: [gogs_account_token]
gogs_url: https://git.openprivacy.ca