Separated nyxt into file, added themes, etc

This commit is contained in:
opal
2021-12-21 00:43:41 -08:00
parent 7a42fc0542
commit a731c61582
5 changed files with 191 additions and 36 deletions

View File

@@ -1,43 +1,9 @@
#+TITLE: Desktop Configuration
This =.org= document is where I store all of my user-level application configuration including shells, terminal emulators, browsers etc.
This =.org= document is where I store all of my small time user-level configuration.
I prefer to use programs that I can extend the functionality of via configuration files and source code.
* Nyxt
Nyxt is a browser written in Common Lisp that follows the same philosophy of extensibility as Emacs. This makes it a perfect companion to an Emacs centered eco-system when you need a browser with more features than Eww.
#+begin_src lisp :tangle ~/Dotfiles/.config/nyxt/init.lisp :mkdirp yes
;; Set default modes when opening Nyxt.
(define-configuration buffer
((default-modes (append '(dark-mode
vi-normal-mode) %slot-default%))))
;; Keybindings
;; (Note: Override Map will override any other custom keybindings so use a prefix key.)
(define-configuration buffer
((override-map (define-key %slot-default%
"C-x s" 'nyxt/web-mode:search-buffers
"C-x d" 'delete-current-buffer))))
;; todo: Redirect reddit to teddit
;; (defun old-reddit-handler (request-data)
;; (let ((url (url request-data)))
;; (setf (url request-data)
;; (if (search "reddit.com" (quri:uri-host url))
;; (progn
;; (setf (quri:uri-host url) "old.reddit.com")
;; (log:info "Switching to old Reddit: ~s" (render-url url))
;; url)
;; url)))
;; request-data)
;; (define-configuration web-buffer
;; ((request-resource-hook
;; (hooks:add-hook %slot-default% (make-handler-resource #'old-reddit-handler)))))
;; (See url-dispatching-handler for a simpler way to achieve the same result.)
#+end_src
* Shell
Aside from using e-shell for quick command line usage, I mainly use vterm with Zsh. It's a bit of a complicated setup but allows for the maximum number of files possible to live in .config instead of littering my home directory.