Instead of manually activating the environment for each project, you can reload a declarative shell every time you enter the project’s directory or change the shell.nix inside it. We will use direnv.

Read more here.