Coder Social home page Coder Social logo

Comments (6)

chriz-zeller avatar chriz-zeller commented on May 19, 2024 1

I'm not sure about this, but we could try the following or a variant of it:

language: haskell

ghc:
  - "7.6.3"
  - "7.8.4"
  - "7.10.3"
  - "8.0.2"
  - "8.2.1"
env
  - PACKAGE="dunai" PACKAGE_DIR="."
  - PACKAGE="bearriver" PACKAGE_DIR="examples/bearriver"
  
install:
 - travis_retry sudo apt-get update
 - travis_retry sudo apt-get install cabal-install-1.24 alex-3.1.4 happy-1.19.5
 - export PATH=$HOME/.cabal/bin:/opt/cabal/1.24/bin:/opt/alex/3.1.4/bin:/opt/happy/1.19.5/bin:$PATH
 - travis_retry cabal update

I'm not sure whether the ghc variable needs language haskell. And I'm not sure whether it is good to let travis organise the installation of the ghc instead of doing it on our own.

from dunai.

turion avatar turion commented on May 19, 2024

Stupid question. Is it not a problem that the password is public then?

Btw, if you want to avoid duplicating the list of subpackages every time, you can do the thing described in https://docs.travis-ci.com/user/languages/haskell/#Build-Matrix.

from dunai.

ivanperez-keera avatar ivanperez-keera commented on May 19, 2024

It won't be public. It'll be encrypted by Travis. But it'll be visible by anyone with commit access to the repo, which is why it's best to have a different user for this.

from dunai.

ivanperez-keera avatar ivanperez-keera commented on May 19, 2024

I just took a quick look. It seems to me that, since packages need to be compiled with a range of GHC versions, the cleanest way to do this would be to specify a build matrix that provides all possible combinations:

env:
 - GHCVER=7.6.3  PACKAGE="dunai"     PACKAGE_DIR="."
 - GHCVER=7.8.4  PACKAGE="dunai"     PACKAGE_DIR="."
 - GHCVER=7.10.3 PACKAGE="dunai"     PACKAGE_DIR="."
 - GHCVER=8.0.2  PACKAGE="dunai"     PACKAGE_DIR="."
 - GHCVER=8.2.1  PACKAGE="dunai"     PACKAGE_DIR="."

 - GHCVER=7.6.3  PACKAGE="bearriver" PACKAGE_DIR="examples/bearriver"
 - GHCVER=7.8.4  PACKAGE="bearriver" PACKAGE_DIR="examples/bearriver"
 - GHCVER=7.10.3 PACKAGE="bearriver" PACKAGE_DIR="examples/bearriver"
 - GHCVER=8.0.2  PACKAGE="bearriver" PACKAGE_DIR="examples/bearriver"
 - GHCVER=8.2.1  PACKAGE="bearriver" PACKAGE_DIR="examples/bearriver"

Is there a simpler way? (yes, we can eliminate PACKAGE_DIR if we put dunai in a subdir and bearriver in another, but that's not what I am asking.)

from dunai.

ivanperez-keera avatar ivanperez-keera commented on May 19, 2024

You're absolutely right. I didn't know the current haskell image on travis had other versions of GHC installed (it didn't use to be the case). This simplifies the build process a lot.

Thanks!

from dunai.

turion avatar turion commented on May 19, 2024

@chriz-keera 's approach seems the right one to me. I don't think we need all those directives listed after install:. Travis should be able to figure this out on its own.

from dunai.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.