-
-
Notifications
You must be signed in to change notification settings - Fork 35
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
project-compile not applying env when switching projects #59
Comments
Hmmm, that case is actually tricky to address: there's no buffer in the destination ("other") project in which You can work around it by doing this: (defun my/ensure-current-project (fn &rest args)
(let ((default-directory (project-root (project-current t))))
(with-temp-buffer
(envrc-mode 1)
(apply fn args))))
(advice-add 'project-compile :around #'my/ensure-current-project) for now, but I'll have a think about how to address this more thoroughly. |
One tricky thing here is that users might not have Note also that |
It works. Thank you very much. |
But a question, I check |
Yes, I think you're saying that The sequence in
|
So it's all a bit unfortunate, because the |
Thank you for taking time to explain to me. I understood more. |
Me too — until you asked, I didn't actually realise that |
Hello,
I am currently experiencing an issue with
project-compile
. I usually switch to a project by callproject-compile
directly.This is my configuration:
em -Q --load config.el
When I call
M-x project-compile
and select another project that has a.envrc
file, the environment does not get applied.I have tried to debug the issue, but was unable to identify the root cause.
Thank you.
The text was updated successfully, but these errors were encountered: