Use function for switching treemacs workspace

This commit is contained in:
Kiana Sheibani 2024-02-25 00:06:44 -05:00
parent 883bafff65
commit 42935deb6b
Signed by: toki
GPG key ID: 6CB106C25E86A9F7

View file

@ -1964,7 +1964,7 @@ convenience function ensures that only the project directory is open.
(append (remove-if (lambda (w) (string= (treemacs-workspace->name w) name))
treemacs--workspaces)
(list workspace)))
(setf (treemacs-current-workspace) workspace)
(treemacs-do-switch-workspace workspace)
(treemacs--invalidate-buffer-project-cache)
(treemacs--rerender-after-workspace-change))))
#+end_src