mirror of
https://github.com/doomemacs/doomemacs
synced 2025-08-01 12:17:25 -05:00
Move :tools impatient-mode to new :collab category
This commit is contained in:
25
modules/collab/impatient-mode/autoload.el
Normal file
25
modules/collab/impatient-mode/autoload.el
Normal file
@ -0,0 +1,25 @@
|
||||
;;; collab/impatient-mode/autoload.el -*- lexical-binding: t; -*-
|
||||
|
||||
;;;###autoload
|
||||
(defun +impatient-mode/toggle ()
|
||||
"TODO"
|
||||
(interactive)
|
||||
(require 'simple-httpd)
|
||||
(unless (process-status "httpd")
|
||||
(httpd-start))
|
||||
(impatient-mode)
|
||||
(if impatient-mode
|
||||
(add-hook 'kill-buffer-hook '+impatient-mode--cleanup-impatient-mode)
|
||||
(+impatient-mode--cleanup-impatient-mode)))
|
||||
|
||||
(defun +impatient-mode--cleanup-impatient-mode ()
|
||||
(unless (cl-loop for buf in (doom-buffer-list)
|
||||
if (buffer-local-value 'impatient-mode buf)
|
||||
return t)
|
||||
(httpd-stop)
|
||||
(cl-loop for buf in (doom-buffer-list)
|
||||
if (buffer-local-value 'impatient-mode buf)
|
||||
do
|
||||
(with-current-buffer buf
|
||||
(impatient-mode -1)))
|
||||
(remove-hook 'kill-buffer-hook '+impatient-mode--cleanup-impatient-mode)))
|
6
modules/collab/impatient-mode/config.el
Normal file
6
modules/collab/impatient-mode/config.el
Normal file
@ -0,0 +1,6 @@
|
||||
;;; collab/impatient-mode/config.el -*- lexical-binding: t; -*-
|
||||
|
||||
;; Show off code as you write it
|
||||
|
||||
(def-package! impatient-mode
|
||||
:commands impatient-mode)
|
5
modules/collab/impatient-mode/packages.el
Normal file
5
modules/collab/impatient-mode/packages.el
Normal file
@ -0,0 +1,5 @@
|
||||
;; -*- no-byte-compile: t; -*-
|
||||
;;; collab/impatient-mode/packages.el
|
||||
|
||||
(package! htmlize)
|
||||
(package! impatient-mode)
|
Reference in New Issue
Block a user