[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/setup 757de04 21/25: Replace yasnippet example with dir
From: |
Stefan Monnier |
Subject: |
[elpa] externals/setup 757de04 21/25: Replace yasnippet example with dired |
Date: |
Wed, 14 Apr 2021 18:49:03 -0400 (EDT) |
branch: externals/setup
commit 757de049f3272f206ee56bacd9bc973b9cc3e8ca
Author: Philip K <philipk@posteo.net>
Commit: Philip K <philipk@posteo.net>
Replace yasnippet example with dired
---
README.md | 31 ++++++++++++++-----------------
setup.el | 31 ++++++++++++++-----------------
2 files changed, 28 insertions(+), 34 deletions(-)
diff --git a/README.md b/README.md
index a97a7ff..00e304a 100644
--- a/README.md
+++ b/README.md
@@ -10,16 +10,15 @@ example, these macros:
(:global key shell)
(:bind key bury-buffer)))
+(setup dired
+ (:also-load dired-x)
+ (:option (prepend dired-guess-shell-alist-user) '("" "xdg-open")
+ dired-dwim-target t")
+ (:hook auto-revert-mode))
+
(setup (:package paredit)
(:hide-mode)
(:hook-into scheme-mode lisp-mode))
-
-(setup (:package yasnippet)
- (:with-mode yas-minor-mode
- (:rebind "<backtab>" yas-expand)
- (:option yas-prompt-functions '(yas-completing-prompt)
- yas-wrap-around-region t)
- (:hook-into prog-mode)))
~~~
will be replaced with the functional equivalent of
@@ -29,6 +28,14 @@ will be replaced with the functional equivalent of
(with-eval-after-load 'shell
(define-key shell-mode-map (kbd "C-c s") #'bury-buffer))
+(with-eval-after-load 'dired
+ (require 'dired-x))
+(customize-set-variable 'dired-guess-shell-alist-user
+ (cons '("" "xdg-open")
+ dired-guess-shell-alist-user))
+(customize-set-variable 'dired-dwim-target t)
+(add-hook 'dired-mode-hook #'auto-revert-mode)
+
(unless (package-install-p 'paredit)
(package-install 'paredit))
(setq minor-mode-alist
@@ -36,16 +43,6 @@ will be replaced with the functional equivalent of
minor-mode-alist))
(add-hook 'scheme-mode-hook #'paredit-mode)
(add-hook 'lisp-mode-hook #'paredit-mode)
-
-(unless (package-install-p 'yasnippet)
- (package-install 'yasnippet))
-(with-eval-after-load 'yasnippet
- (dolist (key (where-is-internal 'yas-expand yas-minor-mode-map))
- (define-key yas-minor-mode-map key nil))
- (define-key yas-minor-mode-map (kbd "<backtab>") #'yas-expand))
-(customize-set-variable 'yas-prompt-functions '(yas-completing-prompt))
-(customize-set-variable 'yas-wrap-around-region t)
-(add-hook 'prog-mode-hook #'yas-minor-mode)
~~~
Additional "keywords" can be defined using `setup-define`. All known
diff --git a/setup.el b/setup.el
index 18527ab..90cded2 100644
--- a/setup.el
+++ b/setup.el
@@ -32,16 +32,15 @@
;; (:global key shell)
;; (:bind key bury-buffer)))
;;
+;; (setup dired
+;; (:also-load dired-x)
+;; (:option (prepend dired-guess-shell-alist-user) '("" "xdg-open")
+;; dired-dwim-target t")
+;; (:hook auto-revert-mode))
+;;
;; (setup (:package paredit)
;; (:hide-mode)
;; (:hook-into scheme-mode lisp-mode))
-;;
-;; (setup (:package yasnippet)
-;; (:with-mode yas-minor-mode
-;; (:rebind "<backtab>" yas-expand)
-;; (:option yas-prompt-functions '(yas-completing-prompt)
-;; yas-wrap-around-region t)
-;; (:hook-into prog-mode)))
;; will be replaced with the functional equivalent of
@@ -49,6 +48,14 @@
;; (with-eval-after-load 'shell
;; (define-key shell-mode-map (kbd "C-c s") #'bury-buffer))
;;
+;; (with-eval-after-load 'dired
+;; (require 'dired-x))
+;; (customize-set-variable 'dired-guess-shell-alist-user
+;; (cons '("" "xdg-open")
+;; dired-guess-shell-alist-user))
+;; (customize-set-variable 'dired-dwim-target t)
+;; (add-hook 'dired-mode-hook #'auto-revert-mode)
+;;
;; (unless (package-install-p 'paredit)
;; (package-install 'paredit))
;; (setq minor-mode-alist
@@ -56,16 +63,6 @@
;; minor-mode-alist))
;; (add-hook 'scheme-mode-hook #'paredit-mode)
;; (add-hook 'lisp-mode-hook #'paredit-mode)
-;;
-;; (unless (package-install-p 'yasnippet)
-;; (package-install 'yasnippet))
-;; (with-eval-after-load 'yasnippet
-;; (dolist (key (where-is-internal 'yas-expand yas-minor-mode-map))
-;; (define-key yas-minor-mode-map key nil))
-;; (define-key yas-minor-mode-map (kbd "<backtab>") #'yas-expand))
-;; (customize-set-variable 'yas-prompt-functions '(yas-completing-prompt))
-;; (customize-set-variable 'yas-wrap-around-region t)
-;; (add-hook 'prog-mode-hook #'yas-minor-mode)
;; Additional "keywords" can be defined using `setup-define'. All
;; known keywords are documented in the docstring for `setup'.
- [elpa] externals/setup e1d51a3 07/25: Add (remove VAR) form for :option, (continued)
- [elpa] externals/setup e1d51a3 07/25: Add (remove VAR) form for :option, Stefan Monnier, 2021/04/14
- [elpa] externals/setup 7699c78 08/25: Reindent commentary examples, Stefan Monnier, 2021/04/14
- [elpa] externals/setup c707965 10/25: Handle symbols in :global, :bind, :unbind and :rebind, Stefan Monnier, 2021/04/14
- [elpa] externals/setup ea52eb1 17/25: Add note that :option does not manipulate user theme., Stefan Monnier, 2021/04/14
- [elpa] externals/setup 2503ad0 25/25: Expand load path for :load-from, Stefan Monnier, 2021/04/14
- [elpa] externals/setup d44d333 20/25: Add :load-from macro, Stefan Monnier, 2021/04/14
- [elpa] externals/setup 5728369 18/25: Fix shell example in README and Commentary section, Stefan Monnier, 2021/04/14
- [elpa] externals/setup 22b5312 23/25: Add :file-match macro, Stefan Monnier, 2021/04/14
- [elpa] externals/setup f7d5906 16/25: Replace customize-set-variable with the necessary parts, Stefan Monnier, 2021/04/14
- [elpa] externals/setup b7aa594 19/25: Allow :hook-into to also use hook names, Stefan Monnier, 2021/04/14
- [elpa] externals/setup 757de04 21/25: Replace yasnippet example with dired,
Stefan Monnier <=
- [elpa] externals/setup bc0edb4 24/25: Handle argument list for :load-from properly, Stefan Monnier, 2021/04/14
- [elpa] externals/setup 32e4f7f 22/25: Fix syntax in examples, Stefan Monnier, 2021/04/14