|
|
|
@ -18,6 +18,12 @@ |
|
|
|
|
(setq visible-bell t) |
|
|
|
|
(setq vc-handled-backends nil) |
|
|
|
|
|
|
|
|
|
;; only show line numbers in programming mode |
|
|
|
|
(defun display-numbers-hook () |
|
|
|
|
(display-line-numbers-mode t)) |
|
|
|
|
(add-hook 'prog-mode-hook 'display-numbers-hook) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
(setq mouse-wheel-scroll-amount '(1 ((shift) . 1))) ;; one line at a time |
|
|
|
|
(setq mouse-wheel-progressive-speed nil) ;; don't accelerate scrolling |
|
|
|
|
(setq mouse-wheel-follow-mouse 't) ;; scroll window under mouse |
|
|
|
@ -52,7 +58,105 @@ Return a list of installed packages or nil for every skipped package." |
|
|
|
|
(or (file-exists-p package-user-dir) |
|
|
|
|
(package-refresh-contents)) |
|
|
|
|
|
|
|
|
|
(ensure-package-installed 'use-package 'ivy 'magit 'centaur-tabs 'eglot 'telephone-line 'dashboard 'multiple-cursors 'flycheck 'which-key 'restart-emacs 'doom-themes 'rainbow-mode 'rainbow-delimiters 'neotree 'all-the-icons 'elpy 'rustic 'simpleclip 'messages-are-flowing 'hl-todo 'format-all 'auctex 'counsel 'swiper 'projectile 'org-roam 'smex 'smartparens 'origami) |
|
|
|
|
(ensure-package-installed 'use-package 'ivy 'magit 'centaur-tabs 'eglot 'telephone-line 'dashboard 'multiple-cursors 'flycheck 'which-key 'restart-emacs 'doom-themes 'rainbow-mode 'rainbow-delimiters 'all-the-icons 'elpy 'rustic 'simpleclip 'messages-are-flowing 'hl-todo 'format-all 'auctex 'counsel 'swiper 'projectile 'org-roam 'smex 'smartparens 'origami 'dumb-jump 'kaolin-themes 'company-quickhelp 'treemacs 'treemacs-projectile 'treemacs-magit 'treemacs-icons-dired) |
|
|
|
|
|
|
|
|
|
(use-package treemacs |
|
|
|
|
:ensure t |
|
|
|
|
:defer t |
|
|
|
|
:init |
|
|
|
|
(with-eval-after-load 'winum |
|
|
|
|
(define-key winum-keymap (kbd "M-0") #'treemacs-select-window)) |
|
|
|
|
:config |
|
|
|
|
(progn |
|
|
|
|
(setq treemacs-collapse-dirs (if treemacs-python-executable 3 0) |
|
|
|
|
treemacs-deferred-git-apply-delay 0.5 |
|
|
|
|
treemacs-directory-name-transformer #'identity |
|
|
|
|
treemacs-display-in-side-window t |
|
|
|
|
treemacs-eldoc-display t |
|
|
|
|
treemacs-file-event-delay 5000 |
|
|
|
|
treemacs-file-extension-regex treemacs-last-period-regex-value |
|
|
|
|
treemacs-file-follow-delay 0.2 |
|
|
|
|
treemacs-file-name-transformer #'identity |
|
|
|
|
treemacs-follow-after-init t |
|
|
|
|
treemacs-expand-after-init t |
|
|
|
|
treemacs-git-command-pipe "" |
|
|
|
|
treemacs-goto-tag-strategy 'refetch-index |
|
|
|
|
treemacs-indentation 2 |
|
|
|
|
treemacs-indentation-string " " |
|
|
|
|
treemacs-is-never-other-window nil |
|
|
|
|
treemacs-max-git-entries 5000 |
|
|
|
|
treemacs-missing-project-action 'ask |
|
|
|
|
treemacs-move-forward-on-expand nil |
|
|
|
|
treemacs-no-png-images nil |
|
|
|
|
treemacs-no-delete-other-windows t |
|
|
|
|
treemacs-project-follow-cleanup nil |
|
|
|
|
treemacs-persist-file (expand-file-name ".cache/treemacs-persist" user-emacs-directory) |
|
|
|
|
treemacs-position 'left |
|
|
|
|
treemacs-read-string-input 'from-child-frame |
|
|
|
|
treemacs-recenter-distance 0.1 |
|
|
|
|
treemacs-recenter-after-file-follow nil |
|
|
|
|
treemacs-recenter-after-tag-follow nil |
|
|
|
|
treemacs-recenter-after-project-jump 'always |
|
|
|
|
treemacs-recenter-after-project-expand 'on-distance |
|
|
|
|
treemacs-litter-directories '("/node_modules" "/.venv" "/.cask") |
|
|
|
|
treemacs-show-cursor nil |
|
|
|
|
treemacs-show-hidden-files t |
|
|
|
|
treemacs-silent-filewatch nil |
|
|
|
|
treemacs-silent-refresh nil |
|
|
|
|
treemacs-sorting 'alphabetic-asc |
|
|
|
|
treemacs-select-when-already-in-treemacs 'move-back |
|
|
|
|
treemacs-space-between-root-nodes t |
|
|
|
|
treemacs-tag-follow-cleanup t |
|
|
|
|
treemacs-tag-follow-delay 1.5 |
|
|
|
|
treemacs-text-scale nil |
|
|
|
|
treemacs-user-mode-line-format nil |
|
|
|
|
treemacs-user-header-line-format nil |
|
|
|
|
treemacs-wide-toggle-width 70 |
|
|
|
|
treemacs-width 35 |
|
|
|
|
treemacs-width-increment 1 |
|
|
|
|
treemacs-width-is-initially-locked t |
|
|
|
|
treemacs-workspace-switch-cleanup nil) |
|
|
|
|
|
|
|
|
|
;; The default width and height of the icons is 22 pixels. If you are |
|
|
|
|
;; using a Hi-DPI display, uncomment this to double the icon size. |
|
|
|
|
;;(treemacs-resize-icons 44) |
|
|
|
|
|
|
|
|
|
(treemacs-follow-mode t) |
|
|
|
|
(treemacs-filewatch-mode t) |
|
|
|
|
(treemacs-fringe-indicator-mode 'always) |
|
|
|
|
|
|
|
|
|
(pcase (cons (not (null (executable-find "git"))) |
|
|
|
|
(not (null treemacs-python-executable))) |
|
|
|
|
(`(t . t) |
|
|
|
|
(treemacs-git-mode 'deferred)) |
|
|
|
|
(`(t . _) |
|
|
|
|
(treemacs-git-mode 'simple))) |
|
|
|
|
|
|
|
|
|
(treemacs-hide-gitignored-files-mode nil)) |
|
|
|
|
:bind |
|
|
|
|
(:map global-map |
|
|
|
|
("M-0" . treemacs-select-window) |
|
|
|
|
("C-x t 1" . treemacs-delete-other-windows) |
|
|
|
|
("<f8>" . treemacs) |
|
|
|
|
("C-x t B" . treemacs-bookmark) |
|
|
|
|
("C-x t C-t" . treemacs-find-file) |
|
|
|
|
("C-x t M-t" . treemacs-find-tag))) |
|
|
|
|
|
|
|
|
|
(use-package treemacs-projectile |
|
|
|
|
:after (treemacs projectile) |
|
|
|
|
:ensure t) |
|
|
|
|
|
|
|
|
|
(use-package treemacs-icons-dired |
|
|
|
|
:hook (dired-mode . treemacs-icons-dired-enable-once) |
|
|
|
|
:ensure t) |
|
|
|
|
|
|
|
|
|
(use-package treemacs-magit |
|
|
|
|
:after (treemacs magit) |
|
|
|
|
:ensure t) |
|
|
|
|
|
|
|
|
|
(require 'dumb-jump) |
|
|
|
|
(add-hook 'xref-backend-functions #'dumb-jump-xref-activate) |
|
|
|
|
(setq xref-show-definitions-function #'xref-show-definitions-completing-read) |
|
|
|
|
|
|
|
|
|
(require 'origami) |
|
|
|
|
(bind-keys |
|
|
|
@ -110,9 +214,9 @@ Return a list of installed packages or nil for every skipped package." |
|
|
|
|
("C-c _" . wrap-with-underscores) |
|
|
|
|
("C-c `" . wrap-with-back-quotes)) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
(use-package company) |
|
|
|
|
(add-hook 'after-init-hook 'global-company-mode) |
|
|
|
|
(company-quickhelp-mode) |
|
|
|
|
|
|
|
|
|
(use-package eglot :ensure t) |
|
|
|
|
(add-hook 'c++-mode-hook 'eglot-ensure) |
|
|
|
@ -156,9 +260,6 @@ Return a list of installed packages or nil for every skipped package." |
|
|
|
|
(global-set-key (kbd "C-<") 'mc/mark-previous-like-this) |
|
|
|
|
(global-set-key (kbd "C-c C-<") 'mc/mark-all-like-this) |
|
|
|
|
|
|
|
|
|
(require 'neotree) |
|
|
|
|
(global-set-key [f8] 'neotree-toggle) |
|
|
|
|
|
|
|
|
|
(use-package elpy |
|
|
|
|
:ensure t |
|
|
|
|
:defer t |
|
|
|
@ -205,11 +306,15 @@ Return a list of installed packages or nil for every skipped package." |
|
|
|
|
(use-package projectile |
|
|
|
|
:ensure t |
|
|
|
|
:init |
|
|
|
|
(projectile-mode +1) |
|
|
|
|
(projectile-mode +1) |
|
|
|
|
:bind (:map projectile-mode-map |
|
|
|
|
("s-p" . projectile-command-map) |
|
|
|
|
("C-c p" . projectile-command-map))) |
|
|
|
|
|
|
|
|
|
(setq projectile-sort-order 'recentf) |
|
|
|
|
(setq projectile-require-project-root t) |
|
|
|
|
(setq projectile-completion-system 'ivy) |
|
|
|
|
|
|
|
|
|
;; org settings |
|
|
|
|
(setq org-replace-disputed-keys t) |
|
|
|
|
(define-key global-map "\C-cl" 'org-store-link) |
|
|
|
|