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

Build flow for GItHub Actions #32

Merged
merged 2 commits into from
Jun 5, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 35 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
# The present workflow was made based on the following references:
# - https://github.com/stackbuilders/hapistrano/blob/master/.github/workflows/build.yml
---
name: build

on: push

concurrency:
group: build-${{ github.ref }}
cancel-in-progress: true

jobs:
haskell:
strategy:
matrix:
ghc:
- "8.10"
- "8.4.3"
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Install Haskell tooling
uses: haskell/actions/setup@v2
with:
ghc-version: ${{ matrix.ghc }}
cabal-version: "3.6"
- name: Configure project
run: cabal configure --enable-tests
- name: Build project
run: cabal build
- name: Run tests
run: cabal test --test-show-details=direct
- name: Check documentation
run: cabal haddock
24 changes: 23 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,23 @@
.stack-work/
dist
dist-*
cabal-dev
*.o
*.hi
*.hie
*.chi
*.chs.h
*.dyn_o
*.dyn_hi
.hpc
.hsenv
.cabal-sandbox/
cabal.sandbox.config
*.prof
*.aux
*.hp
*.eventlog
.stack-work/
cabal.project.local
cabal.project.local~
.HTF/
.ghc.environment.*
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
[![Build Status](https://travis-ci.org/stackbuilders/atomic-write.svg?branch=master)](https://travis-ci.org/stackbuilders/atomic-write) [![Hackage version](https://img.shields.io/hackage/v/atomic-write.svg)](http://hackage.haskell.org/package/atomic-write)
[![Build](https://github.com/stackbuilders/atomic-write/actions/workflows/build.yml/badge.svg?branch=master)](https://github.com/stackbuilders/atomic-write/actions/workflows/build.yml)
[![Hackage version](https://img.shields.io/hackage/v/atomic-write.svg)](http://hackage.haskell.org/package/atomic-write)

# Atomic Write

Expand Down
2 changes: 2 additions & 0 deletions atomic-write.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,8 @@ test-suite atomic-write-test
, text
, bytestring >= 0.10.4
, hspec

build-tools: hspec-discover >= 2.0 && < 3.0

default-language: Haskell2010
ghc-options: -Wall
Expand Down