No description
  • OCaml 90.7%
  • Shell 9.1%
  • Dune 0.2%
Find a file
2019-09-08 17:13:39 +02:00
caesar Dune 2019-08-23 19:25:03 +02:00
capitalize Dune 2019-08-23 19:25:03 +02:00
dict Dune 2019-08-23 19:25:03 +02:00
duration/lib Dune 2019-08-23 19:25:03 +02:00
files Texttree demo 2019-09-08 17:13:39 +02:00
findch Dune 2019-08-23 19:25:03 +02:00
french Dune 2019-08-23 19:25:03 +02:00
mult Dune 2019-08-23 19:25:03 +02:00
parseint Dune 2019-08-23 19:25:03 +02:00
rope Dune 2019-08-23 19:25:03 +02:00
wordcount/lib Dune 2019-08-23 19:25:03 +02:00
.gitignore Dune 2019-08-23 19:25:03 +02:00
create Dune 2019-08-23 19:25:03 +02:00
dune-project Dune 2019-08-23 19:25:03 +02:00
mono.sh Renamed the repository to ex 2017-10-09 23:26:40 +02:00
README.md Made sudo optional 2017-10-10 00:00:40 +02:00

OCaml Exercises

Setup

You'll need the OCaml package manager:

sudo apt install opam

Individual user

wget https://raw.githubusercontent.com/ghuysmans/ocaml-exercises/master/mono.sh
. mono.sh

Shared .opam

  1. Create an ocaml user who will manage packages. On Debian, sudo adduser ocaml. You may give him sudo privileges, but without them, the enrolment script will tell you what to execute.
  2. Log in as him (su ocaml) and follow the Individual user procedure.
  3. sudo chmod g+w /home/ocaml/.opam/log
  4. Move into the repository (cd ex), git commit whatever you want...
  5. For each user $u, ./enrol $u
  6. Update their repository with the usual git pull command.

Organization

Most exercises (e.g. palindrome.ml) are automatically tested:

  • A test (palindrome_test.ml) tries different inputs (add your own!).
  • An interface (palindrome.mli) defines what you have to make.

Coding environment

Use your favorite editor!

Merlin provides autocomplete features, install it through opam:

opam install merlin
#FIXME user-setup?

vim

'TODO minimal config

VS Code

TODO