From cb30514cbc1d3ff027b98409b1fd024850d3bde8 Mon Sep 17 00:00:00 2001 From: Job Evers-Meltzer Date: Mon, 23 May 2016 12:19:52 -0500 Subject: [PATCH 1/7] fix whitespace --- .travis.yml | 22 ++++++++++------------ 1 file changed, 10 insertions(+), 12 deletions(-) diff --git a/.travis.yml b/.travis.yml index d21cb628d..5257823d5 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,4 +1,3 @@ - matrix: include: - os: linux @@ -17,16 +16,15 @@ before_install: install: true before_script: -- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then openssl aes-256-cbc -k "$ENCRYPTION_SECRET" -in packaging/osx/certs/dist.cer.enc -d -a -out packaging/osx/certs/dist.cer; fi -- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then openssl aes-256-cbc -k "$ENCRYPTION_SECRET" -in packaging/osx/certs/dist.p12.enc -d -a -out packaging/osx/certs/dist.p12; fi -- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then ./packaging/osx/add-key.sh; fi + - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then openssl aes-256-cbc -k "$ENCRYPTION_SECRET" -in packaging/osx/certs/dist.cer.enc -d -a -out packaging/osx/certs/dist.cer; fi + - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then openssl aes-256-cbc -k "$ENCRYPTION_SECRET" -in packaging/osx/certs/dist.p12.enc -d -a -out packaging/osx/certs/dist.p12; fi + - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then ./packaging/osx/add-key.sh; fi script: -- if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then bash packaging/ubuntu/ubuntu_package_setup.sh; fi -- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew upgrade gmp; fi -# the default py2app (v0.9) has a bug that is fixed in the head of /metachris/py2app -- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then pip install git+https://github.com/metachris/py2app; fi -# py2app fails to find jsonrpc unless json-rpc is installed. why? I don't know. -- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then pip install json-rpc; fi -- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then cd packaging/osx/lbry-osx-app; ./setup_app.sh; cd $TRAVIS_BUILD_DIR; fi - + - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then bash packaging/ubuntu/ubuntu_package_setup.sh; fi + - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew upgrade gmp; fi + # the default py2app (v0.9) has a bug that is fixed in the head of /metachris/py2app + - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then pip install git+https://github.com/metachris/py2app; fi + # py2app fails to find jsonrpc unless json-rpc is installed. why? I don't know. + - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then pip install json-rpc; fi + - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then cd packaging/osx/lbry-osx-app; ./setup_app.sh; cd $TRAVIS_BUILD_DIR; fi From ad7d508a3ccbbd819215d311a8f6cc4087d564ee Mon Sep 17 00:00:00 2001 From: Job Evers-Meltzer Date: Mon, 23 May 2016 12:33:47 -0500 Subject: [PATCH 2/7] fail build if version doens't match tag --- .travis.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.travis.yml b/.travis.yml index 5257823d5..8f44cc492 100644 --- a/.travis.yml +++ b/.travis.yml @@ -28,3 +28,5 @@ script: # py2app fails to find jsonrpc unless json-rpc is installed. why? I don't know. - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then pip install json-rpc; fi - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then cd packaging/osx/lbry-osx-app; ./setup_app.sh; cd $TRAVIS_BUILD_DIR; fi + # fail the build if this is a build for a tag and we don't have the versions matching + - if [[ -n "${TRAVIS_TAG}" ]]; then if [[ "v`python setup.py -V`" = "${TRAVIS_TAG}" ]]; then true; else false; fi; fi From dab4427c18e93036cc18f26b9920a101a5588e21 Mon Sep 17 00:00:00 2001 From: Job Evers-Meltzer Date: Mon, 23 May 2016 12:57:22 -0500 Subject: [PATCH 3/7] add deployment section to .travis.yml - not sure if the file name entry will work. --- .travis.yml | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/.travis.yml b/.travis.yml index 8f44cc492..39b1d072d 100644 --- a/.travis.yml +++ b/.travis.yml @@ -30,3 +30,13 @@ script: - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then cd packaging/osx/lbry-osx-app; ./setup_app.sh; cd $TRAVIS_BUILD_DIR; fi # fail the build if this is a build for a tag and we don't have the versions matching - if [[ -n "${TRAVIS_TAG}" ]]; then if [[ "v`python setup.py -V`" = "${TRAVIS_TAG}" ]]; then true; else false; fi; fi + +deploy: + provider: releases + file: "`python setup.py --name`_`python setup.py -V`_amd64.deb" + skip_cleanup: true + on: + tags: true + # this is the oauth token for the lbry-ci user + api_key: + secure: nKdWGROnLNodx9k9nWvq2wezkPvSVL8zF63qjPXjhdOe9kCUbcLp7WnFDYpn9EJj4Pofq/ejeCHwjA+5x7JUP3Szk7SlJV61B4c/5hl64rl7oSKOoKskjdE2jaOG3CJuOUrh0yQ59U3vMMABcsnw/wJaCIuu/erdPIm8g8R+stu1YHOGtl5Y9WiW+zLJn2vc3GooV1TWtki9EnrmFfw0Vrqc4RMVMFB1ojE7ggrK1LIwcmGSbLIYzker1ZRz8SCy+84sGk4//V+2i2NNiz5AkPuG7BBGrU2twE9nD23IlruJAdVdi71P3ytAmi0kKyvxIU4VeNaqyTk9zeL5IB9J5IIgvekHgKcsKhFUZ6QcXT1Xfxl4ELftvWCTHWiewnXFdqLcG9GZiUaE6+7wdalwDAP3tqS2emiibetlBZERHR+RMR00ej+1MBYWGMlTse/0Tglndv0a2qqgAJYLKPRT02hTRYGxZ1MrJe+WGnChRmzwgLVTIgZuiDciFOahN0TYGSORk6OpnZBsxvpzSqDw5UDJx0BmbJ1xMNDFbOs8ubZ9yIpB9yNMGw66FPacOF61XNYnmA68ILC28UtOFKuuHLrUPbM5JmQkDVhtTfFbBnyHefyCLAL4MHvJJKGi1oaOXjYaJ/J095h636/kQ0cHHuVMgoWUQZOQ44xRAz7tMuc= From a22052e85b8686ae05b72ed142bc34d88c08b4d4 Mon Sep 17 00:00:00 2001 From: Job Evers Date: Sat, 28 May 2016 09:31:15 -0500 Subject: [PATCH 4/7] comment out version check --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 39b1d072d..f8b0682d8 100644 --- a/.travis.yml +++ b/.travis.yml @@ -29,7 +29,7 @@ script: - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then pip install json-rpc; fi - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then cd packaging/osx/lbry-osx-app; ./setup_app.sh; cd $TRAVIS_BUILD_DIR; fi # fail the build if this is a build for a tag and we don't have the versions matching - - if [[ -n "${TRAVIS_TAG}" ]]; then if [[ "v`python setup.py -V`" = "${TRAVIS_TAG}" ]]; then true; else false; fi; fi + # - if [[ -n "${TRAVIS_TAG}" ]]; then if [[ "v`python setup.py -V`" = "${TRAVIS_TAG}" ]]; then true; else false; fi; fi deploy: provider: releases From 7385cb0c89f412378afec7a4e8f96a48cdd144e8 Mon Sep 17 00:00:00 2001 From: Job Evers Date: Sat, 28 May 2016 09:54:08 -0500 Subject: [PATCH 5/7] try new filename for travis deployment --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index f8b0682d8..28730d068 100644 --- a/.travis.yml +++ b/.travis.yml @@ -33,7 +33,7 @@ script: deploy: provider: releases - file: "`python setup.py --name`_`python setup.py -V`_amd64.deb" + file: "${TRAVIS_BUILD_DIR}/`python setup.py --name`_`python setup.py -V`_amd64.deb" skip_cleanup: true on: tags: true From f3e6b2ab57e949201b261953133cbd77a56bc17b Mon Sep 17 00:00:00 2001 From: Job Evers Date: Sat, 28 May 2016 10:55:15 -0500 Subject: [PATCH 6/7] on travis, move built deb file for easier access --- packaging/ubuntu/ubuntu_package_setup.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/packaging/ubuntu/ubuntu_package_setup.sh b/packaging/ubuntu/ubuntu_package_setup.sh index f35a78b72..70cd064e4 100755 --- a/packaging/ubuntu/ubuntu_package_setup.sh +++ b/packaging/ubuntu/ubuntu_package_setup.sh @@ -164,3 +164,7 @@ $SUDO chown root:root debian-binary control.tar.gz data.tar.xz ar r "$PACKAGE" debian-binary control.tar.gz data.tar.xz # TODO: we can append to data.tar instead of extracting it all and recompressing + +if [[ -n "${TRAVIS_BUILD_DIR}" ]]; then + mv "${PACKAGE}" "${TRAVIS_BUILD_DIR}/${PACKAGE}" +fi From c967230969305365cb39c3771ae1634b84433a74 Mon Sep 17 00:00:00 2001 From: Job Evers Date: Sat, 28 May 2016 11:04:10 -0500 Subject: [PATCH 7/7] restore version consistency check --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 28730d068..64dbd86cc 100644 --- a/.travis.yml +++ b/.travis.yml @@ -29,7 +29,7 @@ script: - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then pip install json-rpc; fi - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then cd packaging/osx/lbry-osx-app; ./setup_app.sh; cd $TRAVIS_BUILD_DIR; fi # fail the build if this is a build for a tag and we don't have the versions matching - # - if [[ -n "${TRAVIS_TAG}" ]]; then if [[ "v`python setup.py -V`" = "${TRAVIS_TAG}" ]]; then true; else false; fi; fi + - if [[ -n "${TRAVIS_TAG}" ]]; then if [[ "v`python setup.py -V`" = "${TRAVIS_TAG}" ]]; then true; else false; fi; fi deploy: provider: releases