-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathJustfile
60 lines (47 loc) · 984 Bytes
/
Justfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
# SPDX-FileCopyrightText: 2024 Richard Mortier <[email protected]>
#
# SPDX-License-Identifier: ISC
_default:
@just --list
PWD := env("PWD")
DOCDIR := "_build/default/_doc/_html"
BUILDDIR := "_build/install/default/bin"
TARGET := "ocal"
# build targets
build:
dune build @all
# cleanup
clean:
dune clean
# install targets
install: build
dune build @install
ln -sf {{PWD}}/{{BUILDDIR}}/{{TARGET}} ~/.local/bin/
# uninstall targets
uninstall:
dune uninstall
# run any tests
test:
dune runtest
# format sources
format:
dune fmt
# lint everything
lint:
dune build @lint
dune-release lint
# build docs
doc:
dune build @doc
dune build @doc-private
# open the docs for reading
read: doc
handlr open {{DOCDIR}}/index.html || open {{DOCDIR}}
# tag and create a release
release:
dune-release tag
dune-release -vv
# install dependencies
depends:
opam install --yes dune-release odoc
opam install --yes . --deps-only