Skip to content
Snippets Groups Projects
Commit 29f9d535 authored by Jean-Paul Calderone's avatar Jean-Paul Calderone
Browse files

try something completely different

parent 57a6f3b0
Branches
No related tags found
1 merge request!14Try out a CircleCI configuration
# Modeled on https://circleci.com/docs/2.0/language-haskell/
# Copyright 2019 PrivateStorage.io, LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
version: 2.1
jobs:
build:
test:
docker:
- image: "fpco/stack-build:lts"
- image: "nixos/nix:2.2.1"
steps:
- "checkout"
- restore_cache:
# Read about caching dependencies: https://circleci.com/docs/2.0/caching/
name: "Restore Cached Dependencies"
keys:
- paymentserver-haskell-v1-{{ checksum "stack.yaml" }}-{{ checksum "PaymentServer.cabal" }}
- paymentserver-haskell-v1-{{ checksum "stack.yaml" }}
- run:
name: "Resolve/Update Dependencies"
command: "stack --no-terminal setup"
- run:
name: "Run tests"
command: "stack --no-terminal test --coverage"
name: "Install Git"
command: |
# Required for the checkout and run steps
nix-env -i git openssh
- "checkout"
- run:
name: "Install executable"
command: "stack --no-terminal install"
- save_cache:
name: "Cache Dependencies"
key: cci-demo-haskell-v1-{{ checksum "stack.yaml" }}-{{ checksum "PaymentServer.cabal" }}
paths:
- "/root/.stack"
- ".stack-work"
- store_artifacts:
# Upload executable
path: "~/.local/bin/PaymentServer-exe"
destination: "PaymentServer-exe"
name: "Run Tests"
command: |
stack test --coverage
workflows:
version: 2
everything:
jobs:
- "test"
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment