Add project template with projectile
This commit is contained in:
parent
eff1ae6d5c
commit
14512fa38e
2 changed files with 23 additions and 1 deletions
|
|
@ -9,7 +9,7 @@
|
|||
'(org-agenda-files
|
||||
'("~/Documents/notes/20240306172458-homelab.org" "/home/nshields/Documents/notes/daily/2024-03-05.org" "/home/nshields/Documents/notes/daily/2024-03-12.org"))
|
||||
'(package-selected-packages
|
||||
'(undo-tree orderless kubernetes-evil kubernetes multi-vterm projectile evil-collection-vterm org-roam pomodoro company fzf magit-todos dap-mode lsp-ui lsp-mode marginalia vertico evil-collection which-key vterm use-package rainbow-delimiters pdf-tools org-roam-ui org-modern nix-mode magit kagi gruvbox-theme gotham-theme evil doom-themes doom-modeline-now-playing crdt consult-org-roam command-log-mode catppuccin-theme))
|
||||
'(gptel chatgpt-shell consult-projectile undo-tree orderless kubernetes-evil kubernetes multi-vterm projectile evil-collection-vterm org-roam pomodoro company fzf magit-todos dap-mode lsp-ui lsp-mode marginalia vertico evil-collection which-key vterm use-package rainbow-delimiters pdf-tools org-roam-ui org-modern nix-mode magit kagi gruvbox-theme gotham-theme evil doom-themes doom-modeline-now-playing crdt consult-org-roam command-log-mode catppuccin-theme))
|
||||
'(visible-bell nil))
|
||||
(custom-set-faces
|
||||
;; custom-set-faces was added by Custom.
|
||||
|
|
|
|||
22
init.el
22
init.el
|
|
@ -3,6 +3,7 @@
|
|||
(tooltip-mode -1)
|
||||
(set-fringe-mode 10)
|
||||
(menu-bar-mode -1)
|
||||
(winner-mode 1)
|
||||
|
||||
(setq inhibit-startup-message t)
|
||||
(setq visible-bell nil)
|
||||
|
|
@ -218,11 +219,31 @@
|
|||
(use-package magit-todos
|
||||
:defer t)
|
||||
|
||||
(use-package consult
|
||||
:ensure t)
|
||||
|
||||
(use-package consult-projectile
|
||||
:ensure t)
|
||||
|
||||
(defun dw/switch-project-action ()
|
||||
"Switch to a workspace with the project name and start `magit-status'."
|
||||
(persp-switch (projectile-project-name))
|
||||
(magit-status))
|
||||
|
||||
(defun default-project-layout ()
|
||||
"Set up the default window layout for any project."
|
||||
(delete-other-windows) ; Close all other windows
|
||||
(split-window-below) ; Split the window horizontally
|
||||
(other-window 1) ; Move to the new window
|
||||
(projectile-run-vterm) ; Move to the new window
|
||||
(other-window 1) ; Move to the new window
|
||||
(dired (projectile-project-root)) ; Open Dired in the new window
|
||||
(other-window -2)) ; Move back to the second window
|
||||
(defun my-universal-project-setup ()
|
||||
"Set up the project-specific layout and settings for any project."
|
||||
(default-project-layout))
|
||||
|
||||
(add-hook 'projectile-after-switch-project-hook 'my-universal-project-setup)
|
||||
(use-package projectile
|
||||
:diminish projectile-mode
|
||||
:config (projectile-mode)
|
||||
|
|
@ -235,6 +256,7 @@
|
|||
(setq projectile-project-search-path '("~/Code")))
|
||||
(setq projectile-switch-project-action #'projectile-dired))
|
||||
|
||||
|
||||
(global-set-key (kbd "M-n") #'other-window)
|
||||
|
||||
;; emacs-land leader-key
|
||||
|
|
|
|||
Loading…
Reference in a new issue