Skip to content

Commit 5a3b4d3

Browse files
committed
work-in-progress Nix support
with https://github.com/input-output-hk/haskell.nix
1 parent 26bdd60 commit 5a3b4d3

File tree

15 files changed

+279
-22
lines changed

15 files changed

+279
-22
lines changed

.github/workflows/ci.yml renamed to .github/workflows/Cabal.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# modified from https://github.com/jgm/pandoc/blob/master/.github/workflows/ci.yml
2-
name: CI
2+
name: Cabal
33

44
on:
55
push:

.github/workflows/Nix.yml

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
name: Nix
2+
3+
on:
4+
push:
5+
branches:
6+
- '**'
7+
paths-ignore: []
8+
pull_request:
9+
paths-ignore: []
10+
11+
jobs:
12+
linux:
13+
14+
runs-on: ubuntu-20.04
15+
strategy:
16+
fail-fast: false
17+
steps:
18+
- uses: actions/checkout@v2
19+
20+
# https://github.com/marketplace/actions/install-nix
21+
- name: Install Nix
22+
uses: cachix/install-nix-action@v14
23+
with:
24+
extra_nix_config: |
25+
trusted-public-keys = hydra.iohk.io:f/Ea+s+dFdN+3Y/G+FDgSq+a5NEWhJGzdjvKNGv0/EQ= cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY=
26+
substituters = https://hydra.iohk.io https://cache.nixos.org/
27+
- run: nix build

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,8 @@ CodeWorld
22
=========
33

44
[![Build Status](https://travis-ci.org/google/codeworld.svg?branch=master)](https://travis-ci.org/google/codeworld)
5-
[![Build status](https://github.com/google/codeworld/actions/workflows/ci.yml/badge.svg)](https://github.com/google/codeworld/actions/workflows/ci.yml)
5+
[![Build status](https://github.com/google/codeworld/actions/workflows/Cabal.yml/badge.svg)](https://github.com/google/codeworld/actions/workflows/Cabal.yml)
6+
[![Build status](https://github.com/google/codeworld/actions/workflows/Nix.yml/badge.svg)](https://github.com/google/codeworld/actions/workflows/Nix.yml)
67

78
CodeWorld is an educational environment using Haskell. It provides a simple
89
mathematical model for geometric figures, animations, and interactive and

cabal.project

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,12 @@ packages:
22
codeworld-account/
33
codeworld-api/
44
codeworld-auth/
5+
-- codeworld-available-pkgs/
56
codeworld-compiler/
67
codeworld-error-sanitizer/
78
codeworld-game-api/
8-
codeworld-game-server/
9+
-- codeworld-game-server/
910
codeworld-prediction/
10-
codeworld-server/
11-
codeworld-base/
11+
-- codeworld-server/
12+
-- codeworld-base/
1213
funblocks-client/

codeworld-api/codeworld-api.cabal

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ Library
6161
mtl >= 2.2.1 && < 2.3,
6262
random >= 1.1 && < 1.2,
6363
ref-tf >= 0.4 && < 0.5,
64-
reflex >= 0.6.3 && < 0.7,
64+
reflex >= 0.6.3,
6565
template-haskell >= 2.8 && < 2.18,
6666
text >= 1.2.2 && < 1.3,
6767
time >= 1.8 && < 2.0,
@@ -73,7 +73,7 @@ Library
7373
ghcjs-prim,
7474
codeworld-game-api,
7575
codeworld-prediction,
76-
ghcjs-dom >= 0.9 && < 0.9.4,
76+
ghcjs-dom >= 0.9,
7777
transformers
7878
else
7979
Build-depends: blank-canvas >= 0.6 && < 0.8,
@@ -122,7 +122,7 @@ Test-suite unit-tests
122122
mtl >= 2.2.1 && < 2.3,
123123
random >= 1.1 && < 1.2,
124124
ref-tf >= 0.4 && < 0.5,
125-
reflex >= 0.6.3 && < 0.7,
125+
reflex >= 0.6.3,
126126
template-haskell >= 2.8 && < 2.18,
127127
text >= 1.2.2 && < 1.3,
128128
time >= 1.8 && < 2.0,
@@ -134,7 +134,7 @@ Test-suite unit-tests
134134
ghcjs-prim,
135135
codeworld-game-api,
136136
codeworld-prediction,
137-
ghcjs-dom >= 0.9 && < 0.9.4,
137+
ghcjs-dom >= 0.9,
138138
transformers
139139
else
140140
Build-depends: blank-canvas >= 0.6 && < 0.8,

codeworld-available-pkgs/codeworld-available-pkgs.cabal

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@ Library
138138
generics-sop,
139139
ghc-prim,
140140
ghcjs-base,
141-
ghcjs-dom,
141+
ghcjs-dom >=0.9,
142142
ghcjs-perch,
143143
ghcjs-prim,
144144
gray-code,

codeworld-base/codeworld-base.cabal

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ Library
4545
codeworld-api,
4646
ghc-prim,
4747
ghcjs-base,
48-
ghcjs-dom,
48+
ghcjs-dom >=0.9,
4949
mtl,
5050
random,
5151
random-shuffle,

codeworld-compiler/codeworld-compiler.cabal

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -54,16 +54,18 @@ Library
5454
directory,
5555
exceptions,
5656
filepath,
57-
ghc == 8.6.5,
58-
ghc-boot-th == 8.6.5,
57+
ghc,
58+
ghc-boot,
59+
ghc-boot-th,
60+
ghc-lib-parser,
5961
hashable,
6062
haskell-src-exts >= 1.20,
6163
megaparsec >= 7.0.0 && < 8.0.0,
6264
memory,
6365
mtl,
6466
process,
67+
regex-base,
6568
regex-tdfa,
66-
regex-tdfa-text,
6769
split,
6870
syb,
6971
temporary,

codeworld-error-sanitizer/codeworld-error-sanitizer.cabal

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,7 @@ Library
2525
else
2626
Build-depends: array,
2727
regex-base,
28-
regex-tdfa,
29-
regex-tdfa-text
28+
regex-tdfa
3029

3130
Default-language: Haskell2010
3231
Exposed: True
@@ -49,7 +48,6 @@ Test-suite unit-tests
4948
else
5049
Build-depends: array,
5150
regex-base,
52-
regex-tdfa,
53-
regex-tdfa-text
51+
regex-tdfa
5452

5553
Default-language: Haskell2010

codeworld-requirements/codeworld-requirements.cabal

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,8 @@ library
3636
haskell-src-exts >= 1.20,
3737
mtl,
3838
process,
39+
regex-base,
3940
regex-tdfa,
40-
regex-tdfa-text,
4141
syb,
4242
temporary,
4343
text,

0 commit comments

Comments
 (0)