Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Travis for Haskell #51

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

ChristopherKing42
Copy link
Contributor

This adds travis support for Haskell. See this for an example build. You can see that the travis bot ran it in 70.64 ms on average. For those who don't know, travis is a thing for automatically running code. It's free for public projects (like this one). See https://travis-ci.org/ (@atemerev would need to get an account; travis is really cool in general and you can signup using your gitHub account).

It will take about 15 minutes to download dependencies the first time, but after that caching will make it fast.

This adds another machine to test with, if other languages add travis. If not, this will at least test any Haskell pull requests.

Using Travis with multiple languages is tricky. If anyone has a better idea, I'm all ears, but I propose this hack (which may be codified in a CONTRIBUTING.md some day):

  • Name the .haskell.travis.yml (or .foo.travis.yml for language foo)
  • When code needs to be benchmarked, a commit not on master is made to rename it .travis.yml, which will cause a run to start on the pull request page.
  • The commit to rename it is not merged; instead, the one before it is merged.
  • The commit is deleted/reset, or just forgotten when its home branch is deleted, as the case may be.

For example, you would only merge 31c70ee, not b81d87f

I don't really like this solution, so again, I'm all ears if someone has a better way.

Pinging @bitemyapp

@ChristopherKing42
Copy link
Contributor Author

Another benefit is that in the README, we can link directly to specific runs, so it is apparent exactly what build environment was used.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant