# Development directives
[[_TOC_]]
## Set up a development environment, first steps
1. Install [devenv](https://devenv.sh/getting-started/) and
[direnv](https://direnv.net/#basic-installation)
1. enable devenv automatic loading with `direnv allow`
1. carefully read devenv output
1. run `just help`
## Git workflow
The work in this repository should follow a
[GitLab Flow](https://docs.gitlab.com/ee/topics/gitlab_flow.html) workflow.
Commit messages must follow
[Conventional Commits](https://www.conventionalcommits.org/en/v1.0.0)
specification. This is enforced by a pre-commit hook. See the commit history for
a reference on the style of commit messages.
Please make an appropriate use of merge and rebase, as explained in
[this article](https://medium.com/@porteneuve/getting-solid-at-git-rebase-vs-merge-4fa1a48c53aa).
Use rebase when pulling to avoid creating useless merge commits. The best way is
to set in your git config file:
```conf
[pull]
rebase = interactive
```
Use `--no-ff` when merging a development branch to create a merge commit even if
master has not advanced.
## Unit testing
See [insta](https://docs.rs/insta/latest/insta/).