wip
This commit is contained in:
@@ -318,6 +318,7 @@ We all know what ~git~ does.
|
||||
settings.user.name = "Joe Frikker";
|
||||
settings.user.email = "joe@redbookcattle.com";
|
||||
settings.github.user = "joe@redbookcattle.com";
|
||||
settings.merge.conflictstyle = "zdiff3";
|
||||
};
|
||||
|
||||
programs.delta = {
|
||||
@@ -344,7 +345,7 @@ The best text editor ever? Heresy!
|
||||
auto-save.after-delay.timeout = 1000;
|
||||
cursorline = true;
|
||||
idle-timeout = 0;
|
||||
rulers = [100];
|
||||
rulers = [120];
|
||||
text-width = 100;
|
||||
lsp.goto-reference-include-declaration = false;
|
||||
cursor-shape.insert = "bar";
|
||||
@@ -505,6 +506,7 @@ Then the real lua config:
|
||||
#+BEGIN_SRC lua
|
||||
local config = {}
|
||||
config.default_prog = { '/Users/jfrikker/.nix-profile/bin/zsh', '-l' }
|
||||
config.font = wezterm.font 'Iosevka Term SS14'
|
||||
config.font_size = 13.0
|
||||
-- config.font = wezterm.font("JetBrains Mono")
|
||||
config.inactive_pane_hsb = {
|
||||
@@ -699,6 +701,11 @@ Now we'll set up some keybindings:
|
||||
programs.ghostty = {
|
||||
enable = true;
|
||||
package = pkgs.ghostty-bin;
|
||||
settings = {
|
||||
adjust-cell-height = "15%";
|
||||
font-family = "Iosevka Term SS14";
|
||||
font-size = 13;
|
||||
};
|
||||
};
|
||||
}
|
||||
#+END_SRC
|
||||
@@ -832,6 +839,8 @@ Turn off some default settings that I don't find useful.
|
||||
(column-number-mode t)
|
||||
(setopt auto-save-default nil)
|
||||
(setopt create-lockfiles nil)
|
||||
(setopt enable-recursive-minibuffers t)
|
||||
(setopt line-spacing 0.15)
|
||||
|
||||
(setopt mouse-wheel-tilt-scroll t)
|
||||
(setq-default truncate-lines t)
|
||||
@@ -987,7 +996,7 @@ less so?
|
||||
I'm trying this out. This disables visual selections. It's bold, which is why I like it :)
|
||||
|
||||
#+BEGIN_SRC elisp
|
||||
;; (transient-mark-mode -1)
|
||||
(transient-mark-mode -1)
|
||||
#+END_SRC
|
||||
|
||||
I use tabs to manage multiple "workspaces". I don't tie a project to a tab or anything; often fixing
|
||||
@@ -1082,16 +1091,11 @@ content to be.
|
||||
"\\*compilation\\*"
|
||||
"\\*pnpm:.*"
|
||||
"\\*sly-mrepl *"
|
||||
"\\*Messages\\*"
|
||||
"\\*lispy-message\\*"
|
||||
"\\*EGLOT connections\\*"
|
||||
"\\*trace-output\\*"
|
||||
"\\*occur\\*"
|
||||
".*eshell\\*"
|
||||
"\\*SQL: .*"
|
||||
"magit: *"
|
||||
"magit-revision: .*"
|
||||
"magit-log*"
|
||||
"\\*Help\\*"
|
||||
"\\*rustfmt\\*"
|
||||
"\\*slack: .*"
|
||||
@@ -1110,18 +1114,102 @@ content to be.
|
||||
(bind-keys ("C-q" . popper-toggle)
|
||||
("C-;" . popper-cycle))
|
||||
|
||||
(defvar jf/fullscreen-popup--param 'jf/fullscreen-saved-configuration
|
||||
"Key used to stash the window configuration a fullscreen popup replaced.
|
||||
Stored per-tab when `tab-bar-mode' is active, otherwise as a plain frame
|
||||
parameter; see `jf/tab-or-frame-parameter'.")
|
||||
|
||||
(defvar-local jf/fullscreen-popup-p nil
|
||||
"Non-nil in a buffer currently being displayed as a fullscreen popup.")
|
||||
|
||||
(defun jf/current-tab-cell (&optional frame)
|
||||
"Return FRAME's current tab's raw data cell, or nil without `tab-bar-mode'."
|
||||
(and (bound-and-true-p tab-bar-mode)
|
||||
(assq 'current-tab (tab-bar-tabs frame))))
|
||||
|
||||
(defun jf/tab-or-frame-parameter (parameter &optional frame)
|
||||
"Like `frame-parameter', but scoped to FRAME's selected tab when tabs are in use.
|
||||
|
||||
A plain frame parameter is shared by every tab on that frame, which is wrong
|
||||
for state like `jf/fullscreen-popup--param': switching tabs swaps in an
|
||||
entirely different window layout, so \"the layout to restore\" has to travel
|
||||
with the tab, not the frame."
|
||||
(if-let ((tab (jf/current-tab-cell frame)))
|
||||
(alist-get parameter tab)
|
||||
(frame-parameter frame parameter)))
|
||||
|
||||
(defun jf/set-tab-or-frame-parameter (parameter value &optional frame)
|
||||
"Set PARAMETER to VALUE, scoped like `jf/tab-or-frame-parameter'."
|
||||
(if-let ((tab (jf/current-tab-cell frame)))
|
||||
(let ((cell (assq parameter tab)))
|
||||
(if cell
|
||||
(setcdr cell value)
|
||||
(setcdr tab (cons (cons parameter value) (cdr tab)))))
|
||||
(set-frame-parameter frame parameter value)))
|
||||
|
||||
(defun jf/display-buffer-fullscreen (buffer alist)
|
||||
"Display BUFFER, deleting other windows, saving the prior layout.
|
||||
|
||||
Intended for use in `display-buffer-alist' for popups (e.g. Magit
|
||||
status/log) that should take over the frame while displayed, but
|
||||
restore the previous window configuration once closed via either
|
||||
`q' or `popper-toggle' -- both end up calling `quit-window', which
|
||||
is where the restore actually happens; see
|
||||
`jf/quit-window-restore-fullscreen'."
|
||||
(unless (jf/tab-or-frame-parameter jf/fullscreen-popup--param)
|
||||
(jf/set-tab-or-frame-parameter jf/fullscreen-popup--param
|
||||
(current-window-configuration)))
|
||||
(when-let ((window (or (display-buffer-reuse-window buffer alist)
|
||||
(display-buffer-same-window buffer alist)
|
||||
(display-buffer-pop-up-window buffer alist)
|
||||
(display-buffer-use-some-window buffer alist))))
|
||||
(let ((ignore-window-parameters t))
|
||||
(delete-other-windows window))
|
||||
(with-current-buffer buffer
|
||||
(setq jf/fullscreen-popup-p t))
|
||||
window))
|
||||
|
||||
(defun jf/quit-window-restore-fullscreen (orig-fn &optional kill window)
|
||||
"Restore the saved window configuration after quitting a fullscreen popup.
|
||||
|
||||
Advice around `quit-window' so both `q' (which Magit and other
|
||||
special-mode buffers bind to buffer-quitting commands that call
|
||||
`quit-window') and Popper's close/toggle commands (which also call
|
||||
`quit-window' directly) trigger the restore. Only restores once the
|
||||
last fullscreen popup on the tab (or frame, without `tab-bar-mode')
|
||||
has closed, so opening one fullscreen popup from within another
|
||||
falls back to the outer one first."
|
||||
(let* ((window (or window (selected-window)))
|
||||
(was-fullscreen (buffer-local-value 'jf/fullscreen-popup-p
|
||||
(window-buffer window)))
|
||||
(frame (window-frame window)))
|
||||
(funcall orig-fn kill window)
|
||||
(when (and was-fullscreen
|
||||
(not (and (window-live-p window)
|
||||
(buffer-local-value 'jf/fullscreen-popup-p
|
||||
(window-buffer window))))
|
||||
(jf/tab-or-frame-parameter jf/fullscreen-popup--param frame))
|
||||
(let ((conf (jf/tab-or-frame-parameter jf/fullscreen-popup--param frame)))
|
||||
(jf/set-tab-or-frame-parameter jf/fullscreen-popup--param nil frame)
|
||||
(set-window-configuration conf)))))
|
||||
|
||||
(advice-add 'quit-window :around #'jf/quit-window-restore-fullscreen)
|
||||
|
||||
(setq display-buffer-alist
|
||||
'(((or "\\*Flymake diagnostics .*"
|
||||
'(((or "magit: *"
|
||||
"magit-log*"
|
||||
"\\*Messages\\*"
|
||||
"\\*trace-output\\*"
|
||||
"\\*EGLOT connections\\*")
|
||||
(jf/display-buffer-fullscreen))
|
||||
((or "\\*Flymake diagnostics .*"
|
||||
"\\*Embark Export: .*"
|
||||
"\\*Embark Collect .*"
|
||||
"\\*xref\\*"
|
||||
"\\*compilation\\*"
|
||||
"\\*pnpm:.*"
|
||||
"\\*sly-mrepl *"
|
||||
"\\*Messages\\*"
|
||||
"\\*lispy-message\\*"
|
||||
"\\*EGLOT connections\\*"
|
||||
"\\*trace-output\\*"
|
||||
"\\*occur\\*"
|
||||
".*eshell\\*"
|
||||
"\\*SQL: .*")
|
||||
@@ -1131,9 +1219,7 @@ content to be.
|
||||
(window-height . 0.33)
|
||||
(window-parameters (no-delete-other-windows . t)
|
||||
(no-other-window . t)))
|
||||
((or "magit: *"
|
||||
"magit-revision: .*"
|
||||
"magit-log*"
|
||||
((or "magit-revision: .*"
|
||||
"\\*Help\\*"
|
||||
"\\*rustfmt\\*"
|
||||
"\\*slack: .*"
|
||||
@@ -1497,6 +1583,7 @@ I don't like UI elements that insert fake text into the file. They mess up the s
|
||||
(setopt eglot-ignored-server-capabilities '(:inlayHintProvider :semanticTokensProvider))
|
||||
(add-hook 'eglot-managed-mode-hook (lambda () (eglot-inlay-hints-mode -1)) nil t)
|
||||
(setopt eglot-code-action-indications nil)
|
||||
(setopt eglot-events-buffer-config '(:size 300000 :format full))
|
||||
#+END_SRC
|
||||
|
||||
Set up a few useful eglot keys.
|
||||
@@ -2232,7 +2319,7 @@ I like Catppuccin Frappe as my theme. Let's use it in as many places as we can.
|
||||
|
||||
;; (set-face-attribute 'default nil :font "JetBrainsMono Nerd Font" :height 130)
|
||||
;; (set-face-attribute 'fixed-pitch nil :font "JetBrainsMono Nerd Font" :height 130)
|
||||
(set-face-attribute 'default nil :font "Iosevka Term SS14" :height 130 :width 'expanded)
|
||||
(set-face-attribute 'fixed-pitch nil :font "Iosevka Term SS14" :height 130 :width 'expanded)
|
||||
(set-face-attribute 'default nil :font "Iosevka Term SS14" :height 130)
|
||||
(set-face-attribute 'fixed-pitch nil :font "Iosevka Term SS14" :height 130)
|
||||
(set-face-attribute 'variable-pitch nil :font "Iosevka Etoile" :height 130)
|
||||
#+END_SRC
|
||||
|
||||
Reference in New Issue
Block a user