CONTRIBUTING/HACKING: Add note on direnv

Add a note on the use of `direnv`, and the availability of the
`.envrc.sample` file.
This commit is contained in:
Adrian Duke 2026-04-22 17:18:13 +01:00 committed by Fintan Halpenny
parent 8af0b623fe
commit 5d8988b1a2
2 changed files with 15 additions and 0 deletions

View File

@ -286,4 +286,12 @@ When it comes to formatting, here's a model git commit message[1]:
---
### Using `direnv`
The team maintains an `.envrc.sample` file (see [direnv](https://direnv.net/)), that contributors may choose to copy or symlink to their local `.envrc` file.
This provides some basic tooling and setup that is common to the team.
For example, if `nix` is installed, the `flake.nix` and `rust-toolchain.toml` files are automatically watched for updates.
_NOTE: It is suggested you do not use `source_env .envrc.sample` in your `.envrc` as [`direnv`'s security checks](https://direnv.net/man/direnv-stdlib.1.html#codesourceenv-ltfileordirpathgtcode) are not triggered when changes are made to `.envrc.sample`._
[1]: http://tbaggery.com/2008/04/19/a-note-about-git-commit-messages.html

View File

@ -185,3 +185,10 @@ OpenSSH tools to interact with them, eg. `ssh-add`.
Your Radicle secret key is protected with a passphrase (See: `$RAD_PASSPHRASE`).
## Using `direnv`
The team maintains an `.envrc.sample` file (see [direnv](https://direnv.net/)), that contributors may choose to copy or symlink to their local `.envrc` file.
This provides some basic tooling and setup that is common to the team.
For example, if `nix` is installed, the `flake.nix` and `rust-toolchain.toml` files are automatically watched for updates.
_NOTE: It is suggested you do not use `source_env .envrc.sample` in your `.envrc` as [`direnv`'s security checks](https://direnv.net/man/direnv-stdlib.1.html#codesourceenv-ltfileordirpathgtcode) are not triggered when changes are made to `.envrc.sample`._