Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
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
1 change: 1 addition & 0 deletions .dir-locals.el
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
((nil . ((lsp-haskell-server-path . "haskell-language-server"))))
3 changes: 2 additions & 1 deletion .ghci
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
:set prompt "\x03BB: "
:def hg \x -> return $ ":!hoogle \"" ++ x ++ "\""
:def hgi \x -> return $ ":!hoogle --info \"" ++ x ++ "\""
33 changes: 33 additions & 0 deletions .github/workflows/build-with-nix-on-self-hosted.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: build-with-nix

# Trigger the workflow on push or pull request, but only for the master branch
on:
pull_request:
push:
branches: [master]

jobs:
build:
name: build with haskell.nix
runs-on: self-hosted

steps:
- uses: actions/checkout@v2
if: github.event.action == 'opened' || github.event.action == 'synchronize' || github.event.ref == 'refs/heads/master'

- name: Prepare Nix
run: |
./ci/prepare-env/do.sh

- name: Build
run: |
[[ -f ~/.nix-profile/etc/profile.d/nix.sh ]] && . ~/.nix-profile/etc/profile.d/nix.sh
nix-build ./cross-build.nix

#- name: Test
#run: |
#nix-shell --run "cabal v2-test --enable-tests"

#- name: Build Docker Image
#run: |
#nix-build ./docker.nix
51 changes: 51 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
name: CI

# Trigger the workflow on push or pull request, but only for the main branch
on:
pull_request:
push:
branches: [master]

jobs:
cabal:
name: ${{ matrix.os }} / ghc ${{ matrix.ghc }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macOS-latest, windows-latest]
cabal: ["2.4"]
ghc:
- 8.10.7
exclude:
- os: macOS-latest
ghc: 8.8.4
- os: windows-latest
ghc: 8.8.4

steps:
- uses: actions/[email protected]
if: github.event.action == 'opened' || github.event.action == 'synchronize' || github.event.ref == 'refs/heads/master'

- uses: haskell/actions/setup@v1
id: setup-haskell-cabal
name: Setup Haskell
with:
ghc-version: ${{ matrix.ghc }}
cabal-version: ${{ matrix.cabal }}

- name: Freeze
run: |
cabal v2-freeze
- uses: actions/[email protected]
name: Cache ~/.cabal/store
with:
path: ${{ steps.setup-haskell-cabal.outputs.cabal-store }}
key: ${{ runner.os }}-${{ matrix.ghc }}-${{ hashFiles('cabal.project.freeze') }}

- name: Build
run: |
cabal v2-configure --enable-tests --enable-benchmarks --test-show-details=direct
cabal v2-build all
- name: Test
run: |
cabal v2-test all
46 changes: 40 additions & 6 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
### Haskell
dist
dist-*
cabal-dev
Expand All @@ -7,17 +8,50 @@ cabal-dev
*.chs.h
*.dyn_o
*.dyn_hi
.hpc
.hsenv
.cabal-sandbox/
cabal.sandbox.config
*.prof
*.aux
*.hp
*.eventlog
.stack-work/
cabal.project.local
.virtualenv
.hsenv
.hpc
.cabal-sandbox/
cabal.sandbox.config
cabal.config
.ghc.environment.*
.HTF/
# Stack
.stack-work/
stack.yaml.lock

### IDE/support
# Vim
[._]*.s[a-v][a-z]
[._]*.sw[a-p]
[._]s[a-v][a-z]
[._]sw[a-p]
*~
tags

# IntellijIDEA
.idea/
.ideaHaskellLib/
*.iml

# Atom
.haskell-ghc-mod.json

# VS
.vscode/

# Emacs
*#
TAGS

# other
.DS_Store

# nix
result
result-*

Loading