ui/workspaces: fix unrenamed workspace on project-switch #1942

This commit is contained in:
Henrik Lissner 2019-10-25 02:42:23 -04:00
parent f516d4c342
commit 4ccb69dbd0
No known key found for this signature in database
GPG key ID: 5F6C0EA160557395

View file

@ -510,6 +510,8 @@ This be hooked to `projectile-after-switch-project-hook'."
(with-current-buffer (doom-fallback-buffer) (with-current-buffer (doom-fallback-buffer)
(setq default-directory +workspaces--project-dir) (setq default-directory +workspaces--project-dir)
(message "Switched to '%s'" (doom-project-name +workspaces--project-dir))) (message "Switched to '%s'" (doom-project-name +workspaces--project-dir)))
(with-demoted-errors "Workspace error: %s"
(+workspace-rename (+workspace-current-name) (doom-project-name +workspaces--project-dir)))
(unless current-prefix-arg (unless current-prefix-arg
(funcall +workspaces-switch-project-function +workspaces--project-dir))) (funcall +workspaces-switch-project-function +workspaces--project-dir)))
(setq +workspaces--project-dir nil)))) (setq +workspaces--project-dir nil))))