I know it is possible to set local variables for a mode through dir-locals.el. But what could I do if I want to run a command such as:
(shell-command "sass --watch style.sass "static/css/style.css")
or activating a virtual env using:
(pyvenv-activate "env/")
Thank you, I will take a look at direnv. The idea is to run the command once indeed. I know there is hooks when switching project, but how to use them here is out of my knowledge.