From e2b7d878bd6244f6d6a0aea5ad466893cb065f49 Mon Sep 17 00:00:00 2001 From: Vasyl Nahuliak <40458927+vasylnahuliak@users.noreply.github.com> Date: Mon, 18 Nov 2024 10:45:33 +0200 Subject: [PATCH] docs: add docs for fnm configuration (#869) --- docs/configuration.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/docs/configuration.md b/docs/configuration.md index fd277694..84eae07a 100644 --- a/docs/configuration.md +++ b/docs/configuration.md @@ -283,7 +283,7 @@ Provide an [**rc**](https://www.baeldung.com/linux/rc-files) file, which is actu Use cases: - You have a GUI program that runs git hooks (e.g., VSCode) -- You reference executables that are accessible only from a tweaked $PATH environment variable (e.g., when using rbenv or nvm) +- You reference executables that are accessible only from a tweaked $PATH environment variable (e.g., when using rbenv or nvm, fnm) - Or even if your GUI program cannot locate the `lefthook` executable :scream: - Or if you want to use ENV variables that control the executables behavior in `lefthook.yml` @@ -331,6 +331,10 @@ In the rc file, export any new environment variables or modify existing ones. export NVM_DIR="$HOME/.nvm" [ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" +# An fnm way +export FNM_DIR="$HOME/.fnm" +[ -s "$FNM_DIR/fnm.sh" ] && \. "$FNM_DIR/fnm.sh" + # Or maybe just PATH=$PATH:$HOME/.nvm/versions/node/v15.14.0/bin ```