travis-ci

How do I get Sonarcloud to run on pull requests from forks with Travis, Maven & github

拟墨画扇 提交于 2019-11-27 13:38:15
问题 While looking into my recent question Sonarcloud failure with Travis, Maven & github I realised that I was asking the wrong question. I was trying to address a symptom rather than the underlying problem. A project I work on (eclipse/scanning) uses Github as it's repository and Travis with Sonarcloud for continuous integration and code analysis. While the Sonarcloud analysis runs fine on internal pull requests (pull requests from branches pushed directly to eclipse/scanning) it doesn't work

How to deploy to github with file pattern on travis?

杀马特。学长 韩版系。学妹 提交于 2019-11-27 13:31:13
问题 I have created a simple travis configuration which packages an app and tries to deploy the archive file to github. The problem is, I would like to have the version number part of the file name, so i require to use a pattern for the filename. I simply can't get it to work. Configuration is currently: deploy: provider: releases file: "build/distributions/worktrail-app-hub-sync*.zip" on: repo: worktrail/worktrail-app-hub-sync tags: true all_branches: true But it fails with: "/home/travis/.rvm

Travis-CI Auto-Tag Build for GitHub Release

不羁岁月 提交于 2019-11-27 10:57:05
问题 I have been attempting to have Travis-CI automatically post its build product on GitHub Releases whenever a commit is pushed to [master]. Unfortunately, GitHub Releases requires a tag to release with. As a solution, I attempted to have Travis automatically generate and apply a tag to the commit. However, every time Travis updates the repository, it causes the release to fail. As such, what am I doing wrong with my current setup and|or is there a way to do what I have described. My travis.yml:

Referencing current branch in github readme.md

最后都变了- 提交于 2019-11-27 10:04:08
问题 In my github repo's readme.md file I have a Travis-CI badge. I use the following link: https://travis-ci.org/joegattnet/joegattnet_v3.png?branch=staging The obvious problem is that the branch is hardcoded. Is it possible to use some sort of variable so that the branch is the one currently being viewed? 回答1: Not that I know of. GitHub support confirms (through OP Joe Gatt 's comment) The only way to do this would be to pass the link through my own service which would use the github's http

How to deploy an rails app on heroku from travis-ci?

↘锁芯ラ 提交于 2019-11-27 10:01:55
问题 There is any way to deploy a heroku rails app after a travis-ci success build? 回答1: Travis CI now has built-in support for deploying to Heroku: http://about.travis-ci.org/blog/2013-07-09-introducing-continuous-deployment-to-heroku/ 回答2: I just implemented this case with an application of mine. It's actually not that hard to do, but it requires some steps: You need your heroku API key See this gist for an example .travis.yml and get the travis_deployer.rb script Then install the travis gem,

apt-get update fails with 404 in a previously working build

陌路散爱 提交于 2019-11-27 09:40:53
I am running a Travis build and it fails when building the mysql:5.7.27 docker image. The Dockerfile runs apt-get update and then I get an error W: Failed to fetch http://deb.debian.org/debian/dists/jessie-updates/main/binary-amd64/Packages 404 Not Found . Using curl I can see it is redirecting, but the redirect-to URL results in a 404. Has anyone seen this sort of behaviour and have a remedy? Is it basically unfixable until debian makes changes? ➜ ms git:(develop) curl --head http://deb.debian.org/debian/dists/jessie-updates/main/binary-amd64/Packages HTTP/1.1 302 Found Date: Tue, 26 Mar 2019

How to publish to Github Pages from Travis CI?

对着背影说爱祢 提交于 2019-11-27 09:29:53
问题 We are compiling Doxygen docs on the travis-ci server and want to push them onto our gh-pages branch. How do I handle the authorization for git push ? Does someone have an example for using encrypted variables in travis-ci? Should I go for https authorization or for an SSH key? 回答1: Step-by-step example with HTTPS API Token in environment variable Others have mentioned it, but here goes a more detailed procedure. Create a separate repository for the website (optional). This will reduce the

How can I install something on Travis CI without a timeout?

ぃ、小莉子 提交于 2019-11-27 09:03:29
I am trying to test a package build on travis-ci.org, but am coming up against a timeout with pip install scipy: Installing collected packages: scipy Running setup.py install for scipy Running command /home/travis/virtualenv/python2.6.9/bin/python -c "import setuptools, tokenize;__file__='/tmp/pip-build-Fn2gmJ/scipy/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-hWDx9L-record/install-record.txt --single-version-externally-managed --compile --install-headers /home/travis/virtualenv/python2.6.9/include

Using secret api keys on travis-ci

六眼飞鱼酱① 提交于 2019-11-27 06:13:32
I'd like to use travis-ci for one of my projects . The project is an API wrapper, so many of the tests rely on the use of secret API keys. To test locally, I just store them as environment variables. What's a safe way to use those keys on Travis? Travis has a feature to encrypt environment variables ( "Encrypting environment variables" ). This can be used to protect your secret API keys. I've successfully used this for my Heroku API key. All you have to do is install the travis gem, encrypt the string you want and add the encrypted string in your .travis.yml . The encryption is only valid for

Is there a way to only run a specific set of tests in an Android Gradle project?

痴心易碎 提交于 2019-11-27 06:13:13
问题 I have an Android/Gradle project. Whenever I want to run tests, I run: ./gradlew connectedInstrumentTest which runs all my tests under the test folder of my project. My test folder has several automation tests as well as non-automation tests. I'm mostly interested in running the fast non-automation tests without the slow automation tests. Is there a way to run just a specific set of tests, such as from one specific class or anything similar? I'm basically asking about any kind of separation