To learn more about the e2scrub_all.timer on your system, you can use these systemctl commands:
- View timer details:
systemctl status e2scrub_all.timer
;; This is miraculously all you need to add decent support for python. | |
;; It requires that you have uv installed. Then run `eglot` in a python buffer. | |
(use-package eglot | |
:defer t | |
:config | |
(add-to-list 'eglot-server-programs | |
`(python-mode . ,(split-string "uvx --quiet --from pyright pyright-langserver --stdio")))) | |
;; this is handy for dumping web pages into buffers, to then add them to context for AI with gptel | |
(defun alg/insert-markdown-from-url (url) |
def find_free_port(candidates=[]): | |
for p in (candidates + [0]): | |
with socket.socket(socket.AF_INET, socket.SOCK_STREAM) as s: | |
try: | |
s.bind(('localhost',p)) | |
return s.getsockname()[1] | |
except Exception: | |
logging.info(f"Could not bind to port {p}. Trying another") | |
port = find_free_port([5001,5010,5100]) |
#!/usr/bin/env python3 | |
import os, os.path, sys, urllib.parse, base64, subprocess | |
def on_iterm2(): return 'ITERM_SESSION_ID' in os.environ or os.environ.get('LC_TERMINAL','') == 'iTerm2' | |
def on_macOS(): return sys.platform == 'darwin' | |
def on_remote_host(): return 'SSH_CLIENT' in os.environ or 'SSH_TTY' in os.environ | |
def openurl(url): |
;; This package makes changes to how emacs interprets CSI escape codes, so that | |
;; it better understands "CSI u"-style codes, so that more key chords pass | |
;; through to emacs in terminal mode. | |
;; | |
;; It is intended to work with the following terminal confugration: | |
;; | |
;; - iTerm2 / Keys / Report modifiers using CSI u: enabled | |
;; - iTerm2 / Keys / xterm control sequences can enable modifyOtherKeys mode: enabled | |
;; - iTerm2 / Terminal / Report Terminal Type: xterm-direct | |
;; |