diff options
author | William Carroll <wpcarro@gmail.com> | 2022-08-04T21·27-0700 |
---|---|---|
committer | clbot <clbot@tvl.fyi> | 2022-08-04T21·34+0000 |
commit | 3ebd71dfa2873a6aff6259ed74b2abd80d93de97 (patch) | |
tree | 001a8e8dd31ed7e649087cadb7848c96d431ce95 /users | |
parent | 70a13db93bf0e071a34b39004b38bceee69d7271 (diff) |
refactor(wpcarro/emacs): Remove vterm-mgt.el's dep on dash.el r/4381
TIL (or remembered rather) `seq.el` exists Change-Id: Iec5c21aff7a76906cb24d03bf39bf03f94b67760 Reviewed-on: https://cl.tvl.fyi/c/depot/+/6037 Reviewed-by: wpcarro <wpcarro@gmail.com> Autosubmit: wpcarro <wpcarro@gmail.com> Tested-by: BuildkiteCI
Diffstat (limited to 'users')
-rw-r--r-- | users/wpcarro/emacs/pkgs/vterm-mgt/default.nix | 33 | ||||
-rw-r--r-- | users/wpcarro/emacs/pkgs/vterm-mgt/vterm-mgt.el | 13 |
2 files changed, 22 insertions, 24 deletions
diff --git a/users/wpcarro/emacs/pkgs/vterm-mgt/default.nix b/users/wpcarro/emacs/pkgs/vterm-mgt/default.nix index c97e54e719a2..88eb5502042a 100644 --- a/users/wpcarro/emacs/pkgs/vterm-mgt/default.nix +++ b/users/wpcarro/emacs/pkgs/vterm-mgt/default.nix @@ -1,18 +1,19 @@ { pkgs, depot, ... }: -pkgs.callPackage - ({ emacsPackages }: - emacsPackages.trivialBuild { - pname = "vterm-mgt"; - version = "1.0.0"; - src = ./vterm-mgt.el; - packageRequires = - (with emacsPackages; [ - dash - vterm - ]) ++ - (with depot.users.wpcarro.emacs.pkgs; [ - cycle - ]); - }) -{ } +pkgs.emacsPackages.trivialBuild { + pname = "vterm-mgt"; + version = "1.0.0"; + src = ./vterm-mgt.el; + packageRequires = + (with pkgs.emacsPackages; [ + vterm + ]) ++ + (with depot.users.wpcarro.emacs.pkgs; [ + cycle + ]); + passthru.meta.ci.extraSteps.github = depot.tools.releases.filteredGitPush { + filter = ":/users/wpcarro/emacs/pkgs/vterm-mgt"; + remote = "git@github.com:wpcarro/vterm-mgt.el.git"; + ref = "refs/heads/canon"; + }; +} diff --git a/users/wpcarro/emacs/pkgs/vterm-mgt/vterm-mgt.el b/users/wpcarro/emacs/pkgs/vterm-mgt/vterm-mgt.el index 29c24d89ec9c..fe161fc6fbff 100644 --- a/users/wpcarro/emacs/pkgs/vterm-mgt/vterm-mgt.el +++ b/users/wpcarro/emacs/pkgs/vterm-mgt/vterm-mgt.el @@ -22,16 +22,17 @@ ;; Dependencies ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; -(require 'dash) (require 'cycle) (require 'vterm) +(require 'seq) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; Configuration ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; (defgroup vterm-mgt nil - "Customization options for `vterm-mgt'.") + "Customization options for `vterm-mgt'." + :group 'vterm) (defcustom vterm-mgt-scroll-on-focus nil "When t, call `end-of-buffer' after focusing a vterm instance." @@ -124,9 +125,7 @@ If for whatever reason, the state of `vterm-mgt--instances' is corrupted and restore the state." (interactive) (setq vterm-mgt--instances - (->> (buffer-list) - (-filter #'vterm-mgt--instance?) - cycle-from-list))) + (cycle-from-list (seq-filter #'vterm-mgt--instance? (buffer-list))))) (defun vterm-mgt-select () "Select a vterm instance by name from the list in `vterm-mgt--instances'." @@ -134,9 +133,7 @@ If for whatever reason, the state of `vterm-mgt--instances' is corrupted and (vterm-mgt-reconcile-state) (switch-to-buffer (completing-read "Switch to vterm: " - (->> vterm-mgt--instances - cycle-to-list - (-map #'buffer-name))))) + (seq-map #'buffer-name (cycle-to-list vterm-mgt--instances))))) (provide 'vterm-mgt) ;;; vterm-mgt.el ends here |