Skip to content

Commit 97ae31f

Browse files
authored
Merge pull request #1 from mseri/fixups
Port to dune 2.0 and introduce github actions
2 parents 8e5481c + 09130e3 commit 97ae31f

File tree

10 files changed

+276
-255
lines changed

10 files changed

+276
-255
lines changed

.github/workflows/test.yml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
name: md2mld CI
2+
on:
3+
- push
4+
- pull_request
5+
jobs:
6+
run:
7+
name: Tests
8+
runs-on: ${{ matrix.operating-system }}
9+
strategy:
10+
matrix:
11+
# no special functionality to test in macos-latest or windows-latest
12+
operating-system: [ubuntu-latest]
13+
ocaml-version: [ '4.11.1', '4.10.1', '4.09.1', '4.08.1', '4.07.1', '4.06.1', '4.05.0', '4.04.2', '4.03.0', '4.02.3' ]
14+
steps:
15+
- uses: actions/checkout@master
16+
- uses: avsm/setup-ocaml@v1.0
17+
with:
18+
ocaml-version: ${{ matrix.ocaml-version }}
19+
- run: opam pin add md2mld.dev . --no-action
20+
- run: opam install md2mld --yes --deps-only
21+
- run: opam install -t md2mld

.ocamlformat

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
profile=janestreet
2+
wrap-comments=false
3+
let-binding-spacing=sparse

docs/dune

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,7 @@
44
(action
55
(with-stdout-to
66
%{targets}
7-
(run %{exe:../src/md2mld.exe} -min-header 3 %{deps})
8-
)
9-
)
10-
)
7+
(run %{exe:../src/md2mld.exe} -min-header 3 %{deps}))))
118

129
(documentation
13-
(mld_files index)
14-
)
10+
(mld_files index))

dune-project

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
1-
(lang dune 1.4)
1+
(lang dune 2.0)
2+
(name md2mld)

md2mld.opam

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,9 @@ doc: "https://mseri.github.io/md2mld/"
99
bug-reports: "https://github.com/mseri/md2mld/issues"
1010
depends: [
1111
"ocaml"
12-
"dune" {build & >= "1.4.0"}
12+
"dune" {>= "2.0"}
1313
"base-bytes"
1414
"omd"
1515
]
16-
build: ["dune" "build" "-p" name "-j" jobs]
16+
build: ["dune" "build" "-p" name "-j" jobs "@install" "@runtest" {with-test}]
1717
dev-repo: "git+https://github.com/mseri/md2mld.git"

0 commit comments

Comments
 (0)