@@ -47,55 +47,69 @@ your exercises.
47
47
We assume that the current directory is ` $DIR ` .
48
48
49
49
First, clone the current learn-ocaml source tree:
50
+
50
51
```
51
52
git clone [email protected] :ocaml-sf/learn-ocaml.git && cd learn-ocaml
52
53
```
53
54
54
55
If you do not have a GitHub account, do instead:
56
+
55
57
```
56
58
git clone https://github.com/ocaml-sf/learn-ocaml.git && cd learn-ocaml
57
59
```
58
60
59
61
Get an opam environment (a.k.a "switch") with the learn-ocaml dependencies
60
62
ready:
63
+
61
64
```
62
65
opam switch create . --deps-only --locked
63
66
opam install opam-installer
64
67
eval $(opam env)
65
68
```
69
+
66
70
(Alternatively, use ` opam install . --deps-only ` to install the dependencies in
67
71
your current opam switch, without creating a dedicated one.)
68
72
69
73
70
74
Second, compile and install the platform:
75
+
71
76
```
72
77
make && make opaminstall
73
78
```
74
79
75
80
At this point, you should get a working ` learn-ocaml ` program in
76
81
your path. Try:
82
+
77
83
```
78
84
learn-ocaml --help
79
85
```
86
+
80
87
This should open the manpage of the command-line tool to interact
81
88
with the platform.
82
89
90
+ > ** Note for developers:**
91
+ > An API documentation could be partially generated with the ` make doc ` command.
92
+ > _ Currently, the only two supported modules are ` Test_lib ` and ` Learnocaml_report ` _ .
93
+
83
94
## Step 2: Set up a work directory
84
95
85
96
Now, let us go back to ` $DIR ` and create a root for the source tree of exercises:
97
+
86
98
```
87
99
cd $DIR && cp -fr learn-ocaml/demo-repository my-learn-ocaml-repository
88
100
```
89
101
90
102
## Step 3: Sanity check
91
103
92
104
Check that your installation works:
105
+
93
106
```
94
107
learn-ocaml build --repo my-learn-ocaml-repository
95
108
learn-ocaml serve
96
109
```
97
110
98
111
This should output several lines in your terminal ending with:
112
+
99
113
```
100
114
Starting server on port 8080
101
115
```
0 commit comments