symfonycorp / connect

The SymfonyConnect official API SDK
https://connect.symfony.com/
MIT License
90 stars 40 forks source link

Added .travis.yml #40

Closed lyrixx closed 10 years ago

stof commented 10 years ago

you are missing the before_script section running composer (Travis does not run it by default, which is a shame IMO)

stof commented 10 years ago

@lyrixx FYI, the current setup triggered 2 builds for each of your commits:

given that Travis allows only 5 concurrent jobs per repo owner (in this case the sensiolabs organization), it is best to avoid wasting resources this way (a build requires 6 jobs to run with your current config). There is 2 ways to avoid duplicating builds:

you can look at Behat to see an example of the blacklist in use. The reason is that I'm usign my fork and Konstantin is always using gitflow-like branch names, so a blacklist ensures we will not disable builds in release maintenance branch by forgetting to update the whitelist (it happened for us in the past). If you don't have a pattern for your feature branches, you will need to use a whitelist instead, like this:

branches:
  only:
    - master
    # Maintenance branches 
    - '/^\d\.\d$/'
lyrixx commented 10 years ago

@stof Thanks a lot for this explanation.

So IIUC, If I choose to build only master, will travis build all PR? I so I think it's the best way to work. Because I don't want to use my fork ;)

stof commented 10 years ago

It will build all PR targetting a branch which is built. So if you whitelist only master, a PR sent to master will be built, while a PR sent to the collaborators branch will not (but the PR sent from collaborators to master will be built)

lyrixx commented 10 years ago

Thanks. I tweaked the .travis.yml. I thinks It's good for the merge.

stof commented 10 years ago

Givent that tests are passing on HHVM currently, I suggest disallowing failures on it. As the library is currently compatible with HHVM, it should stay compatible IMO.

lyrixx commented 10 years ago

Thanks @stof