Merge remote-tracking branch 'upstream/develop' into develop
This commit is contained in:
commit
256121655e
8 changed files with 32 additions and 21 deletions
|
@ -93,7 +93,8 @@ immediately runs it on the current candidate (ending the ivy session)."
|
|||
[remap yank-pop] #'counsel-yank-pop
|
||||
[remap info-lookup-symbol] #'counsel-info-lookup-symbol
|
||||
[remap imenu] #'counsel-imenu
|
||||
[remap recentf-open-files] #'counsel-recentf)
|
||||
[remap recentf-open-files] #'counsel-recentf
|
||||
[remap org-capture] #'counsel-org-capture)
|
||||
:config
|
||||
(set! :popup "^\\*ivy-occur" '((size . 0.35)) '((transient . 0) (quit)))
|
||||
|
||||
|
|
|
@ -194,7 +194,7 @@ Uses `shrink-window-if-larger-than-buffer'."
|
|||
window--sides-inhibit-check nil)
|
||||
(+popup|cleanup-rules)
|
||||
(dolist (prop +popup-window-parameters)
|
||||
(map-delete prop window-persistent-parameters)))))
|
||||
(map-delete window-persistent-parameters prop)))))
|
||||
|
||||
;;;###autoload
|
||||
(define-minor-mode +popup-buffer-mode
|
||||
|
|
|
@ -488,16 +488,7 @@ created."
|
|||
(setq +workspaces--project-dir default-directory))
|
||||
|
||||
;;;###autoload
|
||||
(defun +workspaces|switch-counsel-project-action (project)
|
||||
"A `counsel-projectile-switch-project-action' that creates a dedicated
|
||||
workspace for a new project, before prompting to open a file."
|
||||
(when persp-mode
|
||||
(let ((+workspaces--project-dir project)
|
||||
(inhibit-message t))
|
||||
(+workspaces|switch-to-project))))
|
||||
|
||||
;;;###autoload
|
||||
(defun +workspaces|switch-to-project ()
|
||||
(defun +workspaces|switch-to-project (&optional inhibit-prompt)
|
||||
"Creates a workspace dedicated to a new project. If one already exists, switch
|
||||
to it. Should be hooked to `projectile-after-switch-project-hook'."
|
||||
(when (and persp-mode +workspaces--project-dir)
|
||||
|
@ -516,7 +507,8 @@ to it. Should be hooked to `projectile-after-switch-project-hook'."
|
|||
(+workspace-switch new-name)
|
||||
(unless persp-p
|
||||
(switch-to-buffer (doom-fallback-buffer)))
|
||||
(doom-project-find-file +workspaces--project-dir)
|
||||
(unless inhibit-prompt
|
||||
(doom-project-find-file +workspaces--project-dir))
|
||||
(+workspace-message
|
||||
(format "Switched to '%s' in new workspace" new-name)
|
||||
'success)))
|
||||
|
@ -527,6 +519,14 @@ to it. Should be hooked to `projectile-after-switch-project-hook'."
|
|||
;; Advice
|
||||
;;
|
||||
|
||||
;;;###autoload
|
||||
(defun +workspaces*switch-counsel-project-action (project)
|
||||
"A `counsel-projectile-switch-project-action' that creates a dedicated
|
||||
workspace for a new project, before prompting to open a file."
|
||||
(let ((+workspaces--project-dir project)
|
||||
(inhibit-message t))
|
||||
(+workspaces|switch-to-project 'inhibit-prompt)))
|
||||
|
||||
;;;###autoload
|
||||
(defun +workspaces*autosave-real-buffers (orig-fn &rest args)
|
||||
"Don't autosave if no real buffers are open."
|
||||
|
|
|
@ -98,8 +98,8 @@ Uses `+workspaces-main' to determine the name of the main workspace."
|
|||
(add-hook 'delete-frame-functions #'+workspaces|delete-associated-workspace)
|
||||
|
||||
;; per-project workspaces
|
||||
(setq projectile-switch-project-action #'+workspaces|set-project-action
|
||||
counsel-projectile-switch-project-action #'+workspaces|switch-counsel-project-action)
|
||||
(setq projectile-switch-project-action #'+workspaces|set-project-action)
|
||||
(advice-add #'counsel-projectile-switch-project-by-name :before #'+workspaces*switch-counsel-project-action)
|
||||
(add-hook 'projectile-after-switch-project-hook #'+workspaces|switch-to-project)
|
||||
|
||||
;;
|
||||
|
|
|
@ -13,3 +13,7 @@
|
|||
(def-package! flycheck-crystal
|
||||
:after crystal-mode
|
||||
:config (add-hook 'crystal-mode-hook #'flycheck-mode))
|
||||
|
||||
|
||||
(def-package! inf-crystal
|
||||
:commands (inf-crystal crystal-switch-to-inf))
|
||||
|
|
|
@ -3,4 +3,4 @@
|
|||
|
||||
(package! crystal-mode)
|
||||
(package! flycheck-crystal)
|
||||
|
||||
(package! inf-crystal)
|
||||
|
|
|
@ -11,13 +11,19 @@
|
|||
(package! org-download))
|
||||
|
||||
(when (featurep! +babel)
|
||||
(package! ob-go)
|
||||
(package! ob-mongo)
|
||||
(package! ob-redis)
|
||||
(package! ob-restclient)
|
||||
(package! ob-rust)
|
||||
(package! ob-sql-mode)
|
||||
(package! ob-translate))
|
||||
(package! ob-translate)
|
||||
|
||||
(when (featurep! :lang go)
|
||||
(package! ob-go))
|
||||
(when (featurep! :lang rust)
|
||||
(package! ob-rust))
|
||||
(when (featurep! :lang restclient)
|
||||
(package! ob-restclient))
|
||||
(when (featurep! :lang crystal)
|
||||
(package! ob-crystal)))
|
||||
|
||||
(when (featurep! +export)
|
||||
(package! ox-pandoc)
|
||||
|
|
|
@ -76,7 +76,7 @@
|
|||
:desc "Ex command" :nv ";" #'evil-ex
|
||||
:desc "M-x" :nv ":" #'execute-extended-command
|
||||
:desc "Pop up scratch buffer" :nv "x" #'doom/open-scratch-buffer
|
||||
:desc "Org Capture" :nv "X" #'+org-capture/open
|
||||
:desc "Org Capture" :nv "X" #'org-capture
|
||||
|
||||
;; Most commonly used
|
||||
:desc "Find file in project" :n "SPC" #'projectile-find-file
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue