[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/dtache 79f1d905a9 078/158: Add example of how to enhanc
From: |
ELPA Syncer |
Subject: |
[elpa] externals/dtache 79f1d905a9 078/158: Add example of how to enhance a command with dtach |
Date: |
Wed, 19 Jan 2022 18:57:59 -0500 (EST) |
branch: externals/dtache
commit 79f1d905a92b802edbf270e28d8c7e8bf2f2a776
Author: Niklas Eklund <niklas.eklund@posteo.net>
Commit: Niklas Eklund <niklas.eklund@posteo.net>
Add example of how to enhance a command with dtach
---
README.org | 13 +++++++++++++
1 file changed, 13 insertions(+)
diff --git a/README.org b/README.org
index 8387cba06f..15cc914175 100644
--- a/README.org
+++ b/README.org
@@ -306,6 +306,19 @@ The =dtache= package supports
[[https://www.gnu.org/software/emacs/manual/html_n
(connection-local-set-profiles
'(:application tramp :protocol "ssh") 'remote-dtache)
#+end_src
+** Enhance a command with dtache
+
+A part from the extensions provided with this package the users of =dtache=
can leverage the package to instruct other commands to use =dtache=. Here is an
example where the package =dired-rsync= is modified to utilize =dtache=.
+
+#+begin_src elisp
+ (defun my/dtache-dired-rsync-advice (orig-fun &rest args)
+ "Always run `dired-rsync' with `dtache'."
+ (pcase-let* ((`(,command ,details) args)
+ (dtache--dtach-mode 'new))
+ (apply orig-fun `(,(dtache-dtach-command command t) ,details))))
+
+ (advice-add #'dired-rsync--do-run :around #'my/dtache-dired-rsync-advice)
+#+end_src
** Customize an individual session
- [elpa] externals/dtache 09d378e50a 024/158: Fix read-only problematic, (continued)
- [elpa] externals/dtache 09d378e50a 024/158: Fix read-only problematic, ELPA Syncer, 2022/01/19
- [elpa] externals/dtache 4e99fc9daa 049/158: Deprecate dtache-list-sessions, ELPA Syncer, 2022/01/19
- [elpa] externals/dtache cb1762ffc2 052/158: Add presentation about dtache version 0.2, ELPA Syncer, 2022/01/19
- [elpa] externals/dtache 5d9c8aa54f 053/158: Add macOS support, ELPA Syncer, 2022/01/19
- [elpa] externals/dtache 01a27b4dc2 056/158: Update README with reference to consult-dtache, ELPA Syncer, 2022/01/19
- [elpa] externals/dtache b75af1b9a7 059/158: Update notification setup, ELPA Syncer, 2022/01/19
- [elpa] externals/dtache b47bc3be09 061/158: Update copyright years, ELPA Syncer, 2022/01/19
- [elpa] externals/dtache 182ab7ccc6 064/158: Add integration with consult, ELPA Syncer, 2022/01/19
- [elpa] externals/dtache ea6d8ae426 068/158: Add missing autoloads, ELPA Syncer, 2022/01/19
- [elpa] externals/dtache e2efe466e0 076/158: Improve error handling with dtache-valid-session, ELPA Syncer, 2022/01/19
- [elpa] externals/dtache 79f1d905a9 078/158: Add example of how to enhance a command with dtach,
ELPA Syncer <=
- [elpa] externals/dtache dae6db33db 083/158: Fix various minor problems, ELPA Syncer, 2022/01/19
- [elpa] externals/dtache 52e839ff4a 007/158: Update README with links, ELPA Syncer, 2022/01/19
- [elpa] externals/dtache 7e8727f3a2 020/158: Add TODO to investigate unknown inactive sessions, ELPA Syncer, 2022/01/19
- [elpa] externals/dtache b94baaeecd 021/158: Fix bug in setup notification, ELPA Syncer, 2022/01/19
- [elpa] externals/dtache 763246bffe 026/158: Remove explicit dependency on dtache-env, ELPA Syncer, 2022/01/19
- [elpa] externals/dtache 087e8f4c73 019/158: Update README, ELPA Syncer, 2022/01/19
- [elpa] externals/dtache d574161815 042/158: Simplify buffer handling, ELPA Syncer, 2022/01/19
- [elpa] externals/dtache 1878cefb2f 038/158: Remove embark dependency, ELPA Syncer, 2022/01/19
- [elpa] externals/dtache 3c61776c7f 014/158: Fix dtache initialization, ELPA Syncer, 2022/01/19
- [elpa] externals/dtache 7c07950642 043/158: Implement better encapsulation of database, ELPA Syncer, 2022/01/19