A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from http://docs.haskellstack.org/en/stable/topics/azure_ci/ below:

Azure CI - Stack

Azure CI

This page documents how to use Stack on Azure CI.

Quick Start

Note that you have to create azure pipelines for your project and then you need to put the relevant configuration files:

For a more detailed explanation, you can read further.

Simple and Complex configuration

We provide two fully baked configuration ready to be used on your projects:

!!! note

  It is likely going to be necessary to modify this configuration to match
  the needs of your project, such as tweaking the build matrix to alter
  which GHC versions you test against, or to specify GHC-version-specific
  `stack.yaml` files if necessary. Do not be surprised if it does not work
  the first time around. See the multiple GHC section below for more
  information.
Creating Azure Pipelines

Each of these configurations is ready to be used immediately. But before we go into where to put them, we have to create pipeline for your project in Azure CI platform:

The rest of this document explains the details of common Azure configurations for those of you who want to tweak the above configuration files or write your own.

Note: both Azure and Stack infrastructures are actively developed. We try to document best practices at the moment.

Infrastructure

Note that you need at least one agent to build your code. You can specify which virtual image you want to choose using this configuration:

pool:
  vmImage: ubuntu-latest

The other popular options are macOS-latest, windows-latest for macOS and Windows respectively. You can find the complete list here. You also have the option to select a specific supported ubuntu version like ubuntu-18.08.

Installing Stack

Currently there is only one reasonable way to install Stack: fetch a precompiled binary from GitHub.

- script: |
    mkdir -p ~/.local/bin
    curl -L https://get.haskellstack.org/stable/linux-x86_64.tar.gz | tar xz --wildcards --strip-components=1 -C ~/.local/bin '*/stack'
  displayName: Install Stack
Installing GHC

There are two ways to install GHC:

But we only use the first method of using Stack to download GHC.

Multiple GHC - parametrised builds

For different GHC versions, you probably want to use different project-level configuration files (stack.yaml, by default). If you do not want to put a specific stack.yaml for a particular snapshot and still want to test it, you have specify your snapshot argument in ARGS environment variable (you will see an example below).

strategy:
  matrix:
    GHC 8.0:
      ARGS: "--snapshot lts-9"
    GHC 8.2:
      ARGS: "--snapshot lts-11"
    GHC 8.4:
      ARGS: "--snapshot lts-12"
    GHC 8.6:
      ARGS: "--snapshot lts-14"
    GHC 8.8:
      ARGS: "--snapsht lts-15"
    nightly:
      ARGS: "--snapshot nightly"
Running tests

After the environment setup, actual test running is simple. Command:

stack $ARGS test --bench --no-run-benchmarks --haddock --no-haddock-deps
Other details

Some Stack commands will run for long time. To avoid timeouts, use the timeoutInMinutes for jobs.

Examples

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4