-
Notifications
You must be signed in to change notification settings - Fork 28
/
Copy path.travis.yml
73 lines (73 loc) · 3.32 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
env:
global:
secure: E9tvTxyTR9vkUERNFkhXP9EvwG0RjgGtaI3un2fFW/7/78cQV4hJjLG9Cl6+/vTy7NSWZ64qc+uqN+wxSRDUm8f+v6leslaY6lb9ZCi7bhPX8H9ekIhM1fqmUPHOgoodsx56qmJ35U06D1pkYM6BIKaXorj9RO2Js9I8GSHwF4/EH5PQR1qd7zQB+9cxyJKz2hiJLcBDehKHcecggjtpNTW6mohiLP/7VuA+tLJDO2TMzH10AkX+J0KCZN/qFuW7jsdb9Z5x2pwPh4ldeY4XhQEmyOmqZRu5Ghi+hpXBjdwX08Q3GM0LsnRCofMHZPrP9xMM7P9W3ie5EYeh6Eq+dFWIPupose185UB4y5pVEP0a8pnAt9Crs9kcorrMz1UFa9vdmjqvv0GS+GpGiAQEvm3d4aHnrnlyWdwC/r5aWYeIyvTy+zzZ/EdQvpmCZLhegXRl44ZMUhKH5wd7ygCqdSpFQXBUuaFoAQGyJh3s08K9IWbsCQMS7r04tktrN6mEQFrgrpSqJLKP+UJgd4bMzbkXO8tOh4ErxxQKTBS4aV/hTIlNF2i0p35wRK2eCYUW1x31VoCXwT5db7oNl9w37cKsVvmb1LWaRePn0yX+7lgvSqO6iCYnAv+n5SCK4ngdzTwISb5iyqv5UUIsGmAyYECWli0tgvvnstY+EtG2734=
matrix:
include:
- os: linux
language: node_js
node_js: '14'
env:
- ELECTRON_CACHE=$HOME/.cache/electron
- ELECTRON_BUILDER_CACHE=$HOME/.cache/electron-builder
- os: osx
osx_image: xcode13.2
language: node_js
node_js: '14'
env:
- ELECTRON_CACHE=$HOME/.cache/electron
- ELECTRON_BUILDER_CACHE=$HOME/.cache/electron-builder
cache:
yarn: true
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
install:
- yarn
- yarn upgrade node-sass
- yarn generate-icons
before_script:
- git lfs pull
script:
- |
yarn build
yarn test
ENVS=`env | grep -iE '^(DEBUG|NODE_|ELECTRON_|YARN_|NPM_|CI|CIRCLE|TRAVIS|APPVEYOR_|CSC_|_TOKEN|_KEY|AWS_|STRIP|BUILD_)([A-Z]|_)*=' | sed -n '/^[^\t]/s/=.*//p' | sed '/^$/d' | sed 's/^/-e /g' | tr '\n' ' '`
if [ -n "$TRAVIS_TAG" ]; then
echo '=== starting travis deploy ==='
if [ "$TRAVIS_OS_NAME" == "linux" ]; then
docker run $ENVS --rm \
-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 dist --linux --win"
else
yarn dist
fi
fi
before_cache:
- rm -rf $HOME/.cache/electron-builder/wine
deploy:
provider: releases
api_key:
secure: E9tvTxyTR9vkUERNFkhXP9EvwG0RjgGtaI3un2fFW/7/78cQV4hJjLG9Cl6+/vTy7NSWZ64qc+uqN+wxSRDUm8f+v6leslaY6lb9ZCi7bhPX8H9ekIhM1fqmUPHOgoodsx56qmJ35U06D1pkYM6BIKaXorj9RO2Js9I8GSHwF4/EH5PQR1qd7zQB+9cxyJKz2hiJLcBDehKHcecggjtpNTW6mohiLP/7VuA+tLJDO2TMzH10AkX+J0KCZN/qFuW7jsdb9Z5x2pwPh4ldeY4XhQEmyOmqZRu5Ghi+hpXBjdwX08Q3GM0LsnRCofMHZPrP9xMM7P9W3ie5EYeh6Eq+dFWIPupose185UB4y5pVEP0a8pnAt9Crs9kcorrMz1UFa9vdmjqvv0GS+GpGiAQEvm3d4aHnrnlyWdwC/r5aWYeIyvTy+zzZ/EdQvpmCZLhegXRl44ZMUhKH5wd7ygCqdSpFQXBUuaFoAQGyJh3s08K9IWbsCQMS7r04tktrN6mEQFrgrpSqJLKP+UJgd4bMzbkXO8tOh4ErxxQKTBS4aV/hTIlNF2i0p35wRK2eCYUW1x31VoCXwT5db7oNl9w37cKsVvmb1LWaRePn0yX+7lgvSqO6iCYnAv+n5SCK4ngdzTwISb5iyqv5UUIsGmAyYECWli0tgvvnstY+EtG2734=
file_glob: true
file:
- dist/*.dmg
- dist/*.AppImage
- dist/*.exe
target_commitish: $TRAVIS_COMMIT
tag_name: $TRAVIS_TAG
overwrite: true
skip_cleanup: true
draft: false
on:
repo: moshfeu/y2mp3
tags: true