Skip to content
Permalink
Branch: master
Find file Copy path
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
121 lines (109 sloc) 4.9 KB
matrix:
include:
- os: osx
osx_image: xcode9.4
language: node_js
node_js: '10'
env:
- ELECTRON_CACHE=$HOME/.cache/electron
- ELECTRON_BUILDER_CACHE=$HOME/.cache/electron-builder
- os: linux
services: docker
language: generic
sudo: required
node_js: '10'
addons:
apt:
packages:
- ucommon-utils
cache:
directories:
- node_modules
- "$HOME/.cache/electron"
- "$HOME/.cache/electron-builder"
before_install:
- |
if [ "$TRAVIS_OS_NAME" == "osx" ]; then
mkdir -p /tmp/git-lfs && curl -L https://github.com/github/git-lfs/releases/download/v2.3.1/git-lfs-$([ "$TRAVIS_OS_NAME" == "linux" ] && echo "linux" || echo "darwin")-amd64-2.3.1.tar.gz | tar -xz -C /tmp/git-lfs --strip-components 1
export PATH="/tmp/git-lfs:$PATH"
fi
before_script:
- git lfs pull
script:
- |
if [ "$TRAVIS_OS_NAME" == "linux" ]; then
docker run --rm \
--env-file <(env | grep -v '\r' | grep -iE 'DEBUG|NODE_|ELECTRON_|YARN_|NPM_|CI|CIRCLE|(\b(?!TRAVIS_COMMIT_MESSAGE)TRAVIS)|APPVEYOR_|CSC_|_TOKEN|_KEY|BUILD_') \
-v ${PWD}:/project \
-v ~/.cache/electron:/root/.cache/electron \
-v ~/.cache/electron-builder:/root/.cache/electron-builder \
electronuserland/builder:wine \
/bin/bash -c "yarn --link-duplicates --pure-lockfile && yarn run release --linux"
else
yarn run release -- --mac --win
fi
before_cache:
- rm -rf $HOME/.cache/electron-builder/wine
# On linux create a tar gz file
before_deploy:
- |
if [ "$TRAVIS_OS_NAME" == "linux" ]; then
sudo tar -cvzf ./dist/bunqDesktop-linux-unpacked.tar.gz ./dist/linux-unpacked/*
fi
- ls dist
# Create checksums for dist file
- |
if [ "$TRAVIS_OS_NAME" == "osx" ]; then
find dist/bunqDesktop-*.* -type f -maxdepth 1 -print0 | xargs -0 shasum -a 256 >> dist/CHECKSUMS_OSX.sha256
cat dist/CHECKSUMS_OSX.sha256
else
sha256sum dist/bunqDesktop-*.* >> dist/CHECKSUMS.sha256
cat dist/CHECKSUMS.sha256
fi
# install JQ for curl handling
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then sudo apt-get install jq; else brew install jq; fi
# install latest version of Go with snap
- eval "$(curl -sL https://raw.githubusercontent.com/travis-ci/gimme/master/gimme | GIMME_GO_VERSION=master bash)"
# get the GHR go library
- go version
- export GOPATH="$HOME/go"
- export PATH="$PATH:$GOPATH/bin"
- go get -u github.com/tcnksm/ghr
deploy:
- provider: releases
overwrite: true
tag_name: travis_build
name: travis_build
draft: true
skip_cleanup: true
api_key:
secure: fuXvloxR1qV4Xj8PecoF8gmQHCPukRF3nR7+szuHsoumUusyko0N5QbItdIfYTwpV9pIGwujV5mB0Ya/CKQzILkdlXo+cJzpCvFGJ1Q9wKk9hwLnouOiyF3wsagia8dpX4iLzVEATu4+LM3jol+KlXLGl8OxkGIy5Vifbd5GTbEiSrTxT9cF48/0ubgf/9rjjJyo5exuE30pRLs+m9cqnCSwgwcH6368OfYOlbRSgtGtzR9eEoGlqiNk2UHGmZUwy8dqOhid+meM7IGXwPjua8hrp1/nc/k8+UcwQxxly8xjp8bib6ier+2GbfbwxHiPWUtKFHoNzJlGWfj6xahz6fPL412HGeWVCrbVJcI3bTb/Ed1EjsjQyr4rUwvFnGitzRQAYqg/s2tpl4mVFPYyLgVMnlqiGNMkAaGfqYgErwdCkaYTtWGmLdIUkDsPMCSc4hOlajWNlb2n/ArYHOCmD+KC1KJ8hsJTxXQWD9Tfv5JBKd8g+63YIS+YEifUsxa9W4UhtODsPwBBcot/m4EH1FJS7wsticqB7rbkVq2iiMLWWMOImX47FSBqFG/0ioeWFayLIuDz+Ulvska/Nz4+R0tCQc4t1l1FDT56WI54H4KE2oYIQ8Y3U304mS6URhVRN+561HwzxVJA4halN30H4aOQjhjm5LW1e4PcSRiRalo=
file_glob: true
file:
- dist/bunqDesktop-*.exe
- dist/bunqDesktop-*.dmg
- dist/bunqDesktop-*.deb
- dist/bunqDesktop-*.snap
- dist/bunqDesktop-*.AppImage
- dist/bunqDesktop-linux-unpacked.tar.gz
- dist/CHECKSUMS*.sha256
on:
all_branches: true
condition: $TRAVIS_BRANCH == 'release'
- provider: script
skip_cleanup: true
script: bash ./tasks/ghr-upload.sh
on:
all_branches: true
condition: $TRAVIS_BRANCH == 'snapshot-build' || $TRAVIS_EVENT_TYPE == 'cron'
- provider: script
script: docker run -v $(pwd):$(pwd) -w $(pwd) snapcore/snapcraft sh -c "apt update && snapcraft push dist/bunqDesktop-*.snap --release edge"
skip_cleanup: true
on:
branch: release
condition: $TRAVIS_OS_NAME == 'linux'
after_success:
- openssl aes-256-cbc -K $encrypted_68d7de2f7cf4_key -iv $encrypted_68d7de2f7cf4_iv -in .snapcraft/travis_snapcraft.cfg -out .snapcraft/snapcraft.cfg -d
env:
global:
secure: rYM1Is70EExcOD4B5GddlXVGGgrz3KWQneL+/9BqbBFoKc2gWL+mycrw+5FZLhE55JjKUpOZM/StRDwSgYKqUHc+bwOoF9nHeOih0BNTj18UxvdViN1owR3qrxSr/FYWF5aMt/xOFs9Cv24m0H67t/XPjEOryNrcplnTP7cyrmDQPHjNIvScm046tdiSHYQvtpP5QBdwH2lOnN4IZ6e2b/V1POJwyZzB4w4o6xkseLpV2BShULItwzhbIonTvj5R0jQ/5x4tZHeMh9GvP04Mb3QX6mcqCBghr3ZY/8g4LjBdYmUAFfUyV+MjGKQqEJtb1GBqS1ehZML6CMZ4OBKJp/+JGzDKamOX+WoegvfKanoWhQ1QGOT9/GETbopgx+mLN6a5AJmQKm4pW7KP6Z/sUg6QszN/MZPeIt8KB7myBJSAgGpen4O0My1WUEjRlkm8orMdEDdI8BFuUfbRMQkeeYqc8tu974KE6ormOU+g07/+eA9GRQehADOht5sbuXsW4TjKNbYVWW0iGPIwWps/kzj7vObaF52AtKJPMyaoIDuMPG8Q97jmuYNI+hPf+3P8e7bSXoWsnv2mfmIAhHp38uul9oFeYMzI1y+41O+ICjrxCd8Cks1GdHARSXcXQvWfVISPTsYB7afUo0GuLaAj04YBsiX06gGjhibdGiJmaM0=
You can’t perform that action at this time.