From 84bb01209f43a6b0fc3c2579d0c4f030bc804511 Mon Sep 17 00:00:00 2001 From: jao Date: Tue, 18 Jan 2022 23:30:38 +0000 Subject: power control commands using systemcl --- completion.org | 38 ++++++++++++++++++++++---------------- init.org | 7 +++++-- 2 files changed, 27 insertions(+), 18 deletions(-) diff --git a/completion.org b/completion.org index f7c2c1e..0e52b56 100644 --- a/completion.org +++ b/completion.org @@ -4,17 +4,22 @@ * completion styles #+begin_src emacs-lisp - (setq tab-always-indent 'complete - read-extended-command-predicate #'command-completion-default-include-p - completion-category-defaults nil - completion-cycle-threshold nil - completions-detailed t - completion-show-help nil - completion-show-inline-help nil - completion-ignore-case t - completion-wrap-movement t - completion-auto-select nil - completion-category-overrides '((file (styles . (partial-completion))))) + (setq tab-always-indent 'complete + read-extended-command-predicate #'command-completion-default-include-p + completion-category-defaults nil + completion-cycle-threshold nil + completions-detailed t + completion-show-help nil + completion-show-inline-help nil + completion-ignore-case t + completion-wrap-movement t + completion-auto-select nil + completion-styles '(basic partial-completion substring emacs22) + completion-category-overrides + '((file (styles partial-completion)) + (command (styles initials substring partial-completion)) + (symbol (styles initials substring partial-completion)) + (variable (styles initials substring partial-completion)))) #+end_src * imenu #+begin_src emacs-lisp @@ -62,13 +67,14 @@ mct-live-completion t ;; 'visible mct-completion-blocklist nil mct-completion-passlist '(imenu - Info-goto-node - Info-index - Info-menu + Info-goto-node + Info-index + Info-menu jao-buffer-same-mode - vc-retrieve-tag))) + vc-retrieve-tag))) + (mct-minibuffer-mode 1) - ;; (mct-region-global-mode -1) + ;; (mct-region-mode 1) #+end_src * marginalia diff --git a/init.org b/init.org index fef1454..b6b4792 100644 --- a/init.org +++ b/init.org @@ -573,7 +573,8 @@ (jao-exec-string "xdg-screensaver status"))))) (jao-def-exec jao-xlock-screen "xdg-screensaver" "activate") - (jao-def-exec jao-suspend "sudo" "/usr/sbin/pm-suspend") + (jao-def-exec jao-suspend "sudo" "systemctl" "suspend") + (jao-def-exec jao-poweroff "sudo" "systemctl" "poweroff") (defun jao-lock-screen () (interactive) @@ -585,7 +586,8 @@ ["Sleep" ("l" "lock screen" jao-lock-screen) ("z" "sleep" jao-suspend) - ("u" "enable/disable screensaver" jao-screensaver-toggle)]) + ("u" "enable/disable screensaver" jao-screensaver-toggle) + ("poof" "power-off" jao-poweroff)]) #+end_src *** X clipboard @@ -1799,6 +1801,7 @@ (use-package vterm :ensure t + :demand t :commands (vterm vterm-mode) :init (setq vterm-kill-buffer-on-exit t vterm-copy-exclude-prompt t -- cgit v1.2.3