2019-07-10 23:27:54 +02:00
|
|
|
;; magit
|
|
|
|
(use-package magit
|
|
|
|
:ensure t
|
|
|
|
:init
|
|
|
|
;; (taken from :open https://r0tty.org/git/dotfiles/emacs/tree/.emacs.d/config/development.el)
|
|
|
|
(defun vcsh (repo)
|
|
|
|
"Invoke magit on a vcsh repo. This requires an appropriate entry in `tramp-methods'."
|
|
|
|
(interactive (let ((repos (delq nil
|
|
|
|
(mapcar #'(lambda (name)
|
|
|
|
(if (string-match ".git$" name)
|
|
|
|
(substring name 0 -4)
|
|
|
|
nil))
|
|
|
|
(directory-files "~/.config/vcsh/repo.d")))))
|
|
|
|
(list (completing-read "Repository: " repos nil t))))
|
|
|
|
(magit-status-internal (format "/vcsh:%s:" repo))))
|
|
|
|
|
|
|
|
;; rust
|
|
|
|
(use-package cargo :ensure t)
|
|
|
|
(use-package flycheck-rust :ensure t)
|
|
|
|
|
|
|
|
;; start cargo
|
|
|
|
(add-hook 'rust-mode-hook 'cargo-minor-mode)
|
|
|
|
|
|
|
|
;; yaml
|
|
|
|
(use-package yaml-mode :ensure t)
|
|
|
|
(use-package flycheck-yamllint :ensure t)
|
|
|
|
|
|
|
|
;; paredit
|
2019-11-10 02:59:24 +01:00
|
|
|
(use-package paredit :ensure t)
|
2019-07-10 23:27:54 +02:00
|
|
|
(autoload 'enable-paredit-mode "paredit" "Turn on pseudo-structural editing of Lisp code." t)
|
|
|
|
(add-hook 'emacs-lisp-mode-hook #'enable-paredit-mode)
|
|
|
|
(add-hook 'eval-expression-minibuffer-setup-hook #'enable-paredit-mode)
|
|
|
|
(add-hook 'ielm-mode-hook #'enable-paredit-mode)
|
|
|
|
(add-hook 'lisp-mode-hook #'enable-paredit-mode)
|
|
|
|
(add-hook 'lisp-interaction-mode-hook #'enable-paredit-mode)
|
|
|
|
(add-hook 'scheme-mode-hook #'enable-paredit-mode)
|
|
|
|
|
|
|
|
;; Hack to show only files known to git inside dired; needs the
|
|
|
|
;; `git-find' shell script shim (taken from :open https://r0tty.org/git/dotfiles/emacs/tree/.emacs.d/config/development.el)
|
|
|
|
(defun git-dired (dir)
|
|
|
|
(interactive (list (read-directory-name "Find files in directory: " nil "" t)))
|
|
|
|
(let ((find-program "git-find"))
|
|
|
|
(find-dired dir "")))
|