summaryrefslogtreecommitdiff
path: root/TODO.org
diff options
context:
space:
mode:
authorCraig Jennings <c@cjennings.net>2024-04-07 13:41:34 -0500
committerCraig Jennings <c@cjennings.net>2024-04-07 13:41:34 -0500
commit754bbf7a25a8dda49b5d08ef0d0443bbf5af0e36 (patch)
treef1190704f78f04a2b0b4c977d20fe96a828377f1 /TODO.org
new repository
Diffstat (limited to 'TODO.org')
-rw-r--r--TODO.org4207
1 files changed, 4207 insertions, 0 deletions
diff --git a/TODO.org b/TODO.org
new file mode 100644
index 00000000..15c49a37
--- /dev/null
+++ b/TODO.org
@@ -0,0 +1,4207 @@
+
+
+=== Emacs Config Tasks ===
+
+* Emacs Config Inbox
+** TODO Check into spacious padding mode
+
+Sample Config from Damien Cassou's Emacs Config
+#+BEGIN_QUOTE
+(use-package spacious-padding
+ :demand t
+ :hook (server-after-make-frame . spacious-padding-mode)
+ :config
+ (progn
+ (setq spacious-padding-subtle-mode-line
+ '(:mode-line-active error :mode-line-inactive shadow))))
+
+#+END_QUOTE
+[[https://raw.githubusercontent.com/DamienCassou/emacs.d/master/init.el][]]
+Captured On: [2024-04-06 Sat 10:54]
+* DOING Emacs Config v0.7 [2/4]
+** DONE Supplement Existing Functionality [9/9]
+*** DONE [#B] Make sure eshell has same path as other shells
+CLOSED: [2024-03-27 Wed 14:02]
+it couldn't find build.emacs.src.sh in the path for instance
+
+*** DONE [#B] Create Topic Org-Roam Template in Capture Templates
+CLOSED: [2023-12-03 Sun 14:59]
+*** DONE [#C] Put Eshell on F12 and Vterm on C-F12
+CLOSED: [2024-03-04 Mon 14:54]
+*** DONE [#C] Save Destination Buffer Post Refile
+CLOSED: [2024-04-03 Wed 16:27]
+**** 2024-04-03 Wed @ 16:11:32 -0500 Saving All Org Buffers Instead
+It appears there are several ways that refile occurs. One is through org-capture, and another directly (i.e., interactively). There may be more.
+
+After some searching, I found a way to save only the target file after an org-capture;
+https://emacs.stackexchange.com/questions/19292/org-refile-locks-up-file-when-used-from-org-capture
+#+begin_src emacs-lisp
+ (defun save-after-capture-refile ()
+ (with-current-buffer (marker-buffer org-capture-last-stored-marker)
+ (save-buffer)))
+ (advice-add 'org-capture-refile :after 'save-after-capture-refile)
+#+end_src
+This uses org-capture-last-stored-marker, which wouldn't work calling org-refile interactively.
+
+The only other way that looked safe, was to simply save all org buffers after a refile. This isn't as desirable, but I will need to use it before I know of any negative impacts.
+
+https://github.com/rougier/emacs-gtd/issues/9
+and a discussion
+https://emacs.stackexchange.com/questions/26923/org-mode-getting-errors-when-auto-saving-after-refiling
+
+**** Goal
+I've had Emacs lock up and as a result of killing it, I lost data in the refile in the unsaved buffer. Like cj/bookmark-set-and-save, I think a refile should save the target file it's refiling to.
+
+https://github.com/rougier/emacs-gtd/issues/9
+*** DONE [#B] Change the Name of an Elfeed Feed
+CLOSED: [2024-04-03 Wed 15:01]
+**** 2024-04-03 Wed @ 15:02:41 -0500 Done With Elfeed-org
+Learned you can do that with elfeed-org and adopted it
+**** Goal:
+#+BEGIN_QUOTE
+For others looking to change the name of a feed - it seems that this is now possible by using M-x elfeed-search-set-feed-title, as described here.
+#+END_QUOTE
+[[https://emacs.stackexchange.com/questions/38718/how-do-i-set-a-custom-name-for-a-feed-in-elfeed][How do I set a custom name for a feed in elfeed? - Emacs Stack Exchange]]
+Captured On: [2023-10-30 Mon 10:49]
+*** CANCELLED [#A] Move from Dired-Sidebar to Treemacs
+CLOSED: [2024-03-14 Thu 06:21]
+Treemacs doesn't give me the functionality I wanted.
+I actually wanted to be able to navigate the methods within a source code file.
+*** CANCELLED [#B] Warn when leaving dirty repository
+This doesn't appear to work when tested.
+Installed according to README
+CLOSED: [2024-03-15 Fri 14:01]
+https://github.com/thisirs/vc-check-status#vc-check-status
+*** CANCELLED [#C] Investigate Yeetube
+CLOSED: [2024-04-03 Wed 15:06]
+
+Decided I wasn't going to use Yeetube
+[[https://michal.sapka.me/emacs/watching-youtube-with-emacs/][[Michał Sapka's website] Emacs: watching YouTube with Yeetube and mpv]]
+Captured On: [2024-03-15 Fri 17:02]
+*** CANCELLED [#C] Look Into Github Elpa
+CLOSED: [2024-04-03 Wed 15:08]
+
+Not needed with local elpa-mirror setup
+
+[[https://github.com/10sr/github-elpa][10sr/github-elpa: Build and Publish Your Own ELPA Repositories with GitHub Pages]]
+Captured On: [2023-10-20 Fri 13:28]
+
+** DONE Stabilize Existing Functionality [9/9]
+*** DONE [#A] Error When Attempting to Launch Dirvish Go Menu
+CLOSED: [2024-04-02 Tue 00:06]
+*** DONE [#A] Move All Bugs and Todos in Code Into Project Todo.org
+CLOSED: [2024-04-03 Wed 16:52]
+*** DONE [#B] Bug: Scan Project Directories for Refiling Candidates Fails!
+Fixed as of today!
+CLOSED: [2024-03-30 Sat 19:10]
+*** DONE [#B] Eshell Should Pick Up Aliases and Environment Variables
+CLOSED: [2024-03-27 Wed 14:31]
+*** DONE [#B] Side Arrows No Longer Change Todo State
+CLOSED: [2024-04-04 Thu 10:29]
+error: Command not allowed on this line
+functions are: org-todo-nextset and org-todo-previouset
+*** DONE [#B] Split Windows Should Show Buffer List and Not Show Current Buffer Twice
+CLOSED: [2024-03-27 Wed 14:35]
+
+Note: this was completed much earlier than the timestamp
+#+BEGIN_QUOTE
+Split functions which open the previous buffer in the new window instead of showing the current buffer twice.
+
+(defun ph/vsplit-last-buffer ()
+(interactive)
+(split-window-vertically)
+(other-window 1 nil)
+(switch-to-next-buffer))
+
+(defun ph/hsplit-last-buffer ()
+(interactive)
+(split-window-horizontally)
+(other-window 1 nil)
+(switch-to-next-buffer))
+#+END_QUOTE
+[[https://github.com/pascal-huber/emacs.d#packages][pascal-huber/emacs.d: My emacs setup]]
+Captured On: [2023-10-22 Sun 02:16]
+*** DONE [#C] Check Eshell-visual-commands for Common Apps
+CLOSED: [2024-03-04 Mon 14:53]
+- [X] gotop
+- [X] ncmpcpp
+- [X] nmtui
+*** DONE Regression: 'C-x k' Immediately Kills Current Buffer
+CLOSED: [2024-04-04 Thu 10:35]
+Emacs -Q behavior displays a completing read containing all buffers with the current buffer selected.
+This is the result of overriding that function in cj/invincible-buffers in system-utils.
+**** 2024-04-04 Thu @ 10:35:09 -0500 Solution
+#+begin_src emacs-lisp
+
+ ;; ----------------------------- Invincible Buffers ----------------------------
+ ;; buries buffers on the 'invincible-buffer' list rather than killing them.
+ ;; The keybinding for kill-buffer is remapped to this function.
+
+ (defvar cj/invincible-buffers '("*scratch*" "*Messages*")
+ "Buffers that should not be killed, but buried instead.")
+
+ (defun cj/kill-buffer ()
+ "Bury buffers on invincible-buffers list rather than killing them."
+ (interactive)
+ (let ((target-buffer (completing-read "Kill buffer: "
+ (mapcar 'buffer-name (buffer-list)))))
+ (with-current-buffer target-buffer
+ (if (member (buffer-name (current-buffer)) cj/invincible-buffers)
+ (bury-buffer)
+ (kill-buffer (current-buffer))))))
+
+ (global-set-key [remap kill-buffer] #'cj/kill-buffer)
+#+end_src
+
+*** DONE [#C] Bookmark-save-flag Replaces Bookmark-set-and-save
+CLOSED: [2024-04-03 Wed 15:00]
+remove cj/bookmark-set-and-save if setting bookmark-save-flat to 1 saves when adding/modifying a bookmark
+** DOING v0.7 Bug Fixing (ends 2024.04.18) [5/10]
+*** TODO [#C] Ripgrep Should Put Point on Results Buffer
+*** TODO [#A] Remove Security Keys
+**** Remove OpenAPI Key From ai-config.el
+***** 2024-04-07 Sun @ 13:21:22 -0500 Issue in ai-config.el
+ ;; BUG: .authinfo.gpg not accessed for this key
+**** Purge History to Remove Historical Issues
+Do this after other secrets are removed
+***** Google OAuth file in assets
+****** 2024-04-07 Sun @ 13:23:51 -0500 This One's in History. Fix by Purging History
+***** OpenAPI Key in help-utils.el
+****** 2024-04-07 Sun @ 13:19:10 -0500 Need to Erase History
+Originally, I thought this was a duplicate use-package declaration.
+Now it appears this is in history. I can simply:
+- force delete the .git file
+- recommit everything
+- force push back to github and git.cjennings.net
+- check the security section again to ensure it's gone.
+***** Google OAuth Client ID and Client Secret in org-agenda-config.el
+*** TODO [#A] S-<right> is Undefined Error in Org Mode
+(should be org-agenda-todo-nextset)
+**** 2024-04-07 Sun @ 11:48:44 -0500 it's simply undefined in org-mode
+Looks like I just added it to org-agenda-mode?
+*** TODO [#A] Error When Starting org-drill in cj/org-drill-start
+let: Symbol’s function definition is void: org-drill
+*** TODO [#B] Kill All Windows Also Kills Invisible Buffers
+*** TODO [#B] Mu4e Doesn't Launch Properly on Fresh Archinstall
+Error was something about the mu server exiting.
+**** TODO Setup Archbase for Virtualbox Testing
+**** TODO Run Archsetup
+**** TODO Run Mu4e Install Found in ~/.emacs.d/scripts/
+*** TODO [#C] Dashboard Icons Aren't Correct or Sized Correctly on Fractal
+*** TODO [#C] Check if Including Dired Buffers in Autorevert-mode Slows Tramp
+*** DONE [#B] cj/kill-buffers renamed
+CLOSED: [2024-04-04 Thu 19:17]
+*** DONE [#B] cj/kill-buffers doesn't select current buffer in completing read by default
+CLOSED: [2024-04-04 Thu 19:17]
+*** DONE [#B] cj/kill-buffers should allow adding to invincible-buffers with C-u prefix
+CLOSED: [2024-04-04 Thu 19:33]
+*** DONE [#B] Mu4e Reply All Should Be Default
+CLOSED: [2024-04-04 Thu 20:45]
+make 'r' reply-all (or wide reply) and 'R' reply
+no need to remove 'W' (for wide reply)
+**** 2024-04-04 Thu @ 20:36:56 -0500 Solution Tested to Be Working
+Need to adjust 'mu4e-view-mode'. Within that mode:
+- the reply method is named "mu4e-compose-reply"
+- the reply-all method is named "mu4e-compose-wide-reply"
+
+There doesn't seem to be anything already mapped to "R", so adding the following should enable these changes.
+#+begin_src emacs-lisp
+ (:map mu4e-view-mode-map
+ ("r" . mu4e-compose-wide-reply)
+ ("R" . mu4e-compose-reply))
+#+end_src
+
+Tested both keys on a mail that had many recipients and it behaved in the way I expected.
+*** DONE [#B] cj/hyphenate-whitespace-in-region should leave point where it started
+CLOSED: [2024-04-04 Thu 22:07]
+** DOING Complete v0.7 Release Checklist [7/10]
+- [X] No Open Work
+- [X] WIP Code Empty/Disabled
+- [X] Emacs Config Inbox Zero
+- [X] Perf Testing: Sub-Second Launch Time
+- [X] Successful Launch from Git Clone
+- [ ] Successful Launch from Archsetup
+- [X] Merged cleanly into main branch
+- [X] Main Branch Pushed to github and git.cjennings.net
+- [ ] 2 Week Scenario Testing and Bug Fixing ends: Thursday, April 18, 2024
+- [ ] Mark Release as DONE and Create Tag on Repo
+* Emacs Config v0.8
+** VERIFY Add Around Word or Region
+*** 2024-04-04 Thu @ 22:12:04 -0500 Scenario Testing Verification
+- tested both cases in prog mode with quotes and character
+- tested undo on all the above
+*** 2024-04-04 Thu @ 22:00:49 -0500 Functionality
+
+This method:
+- Prompts the user for a string
+- If the point is on a word and there is no region selected, insert the character before and after the word at point.
+- If a region is selected, insert the character before and after the region
+- If the point is not on a word and there is no region selected, send a helpful appropriate message.
+
+Left in test-code.el
+
+** TODO Hugo Blogging Workflow
+*** 2024-04-04 Thu @ 16:44:40 -0500 Thoughts on Functionality
+The whole blogging workflow should happen in Emacs.
+- Capturing ideas for what to post
+- Working on multiple drafts at once
+- Listing all drafts
+- Checking into main should update website
+- Checking into any other branch name should not update website
+** TODO Mu4e Mail Improvements
+*** TODO Make Default Reply, Reply-all
+I'll need to reply-all more often than not. So, the lowercase 'r' for Mu4e should be 'reply-all' not 'reply'.
+*** TODO Mail Attachment Adding and Saving All
+**** 2024-04-04 Thu @ 21:32:28 -0500 Reminder to Tie Save All With Save
+In order to make the mu4e save attachment feel natural, save and save all shouldn't be so separate.
+Currently (e) for extract saves an attachment, but just gives you a prompt and colon in the minibuffer.
+
+When choosing save an attachment:
+- if mail contains more than one attachment, select one in completing read
+- choose the directory
+When choosing to save all attachments:
+- choose the directory
+
+with a prefix to the method, you would be opening the directory in dired or dirvish.
+**** 2024-04-04 Thu @ 13:31:08 -0500 Research
+***** Save All Attachments With Vertico and Embark
+https://www.reddit.com/r/emacs/comments/p7gvf9/mu4e_how_best_to_save_large_numbers_of/
+It's pretty easy if you use vertico+embark. After running mu4e-view-save-attachments, invoke embark-act-all in the completion menu followed by RET (mu4e-view-save-attachments) to save all attachments, or TAB (vertico-insert) followed by , (comma) next to each file you want to save, then RET (vertico-exit), to save selected attachments.
+***** Adding Multiple Attachments Using Dired
+https://www.reddit.com/r/emacs/comments/nqhyos/how_to_do_mu4e_attachments/
+
+Hi, thanks for responding. I am in a situation similar to : https://emacs.stackexchange.com/questions/14652/attach-multiple-files-from-the-same-directory-to-an-email-message . I would love the possibility of marking multiple files in multiple folders and attaching them all at once.
+
+- xenodium
+An option here is to open a dired buffer, mark the files you want, and invoke gnus-dired-attach (I use it with mu4e). It should ask you if you want to attach them all to your mail composition buffer.
+
+- [deleted]
+Brilliant! Now I just have to define two keybindings. First one to a lambda which can open a dired buffer with turn-on-gnus-dired-mode, and then another one within the keymap to this mode to run gnus-dired-attach. All this, to avoid a couple of M-x commands, because I feel smart when I use keybindings... =.="
+
+- xenodium
+First one to a lambda which can open a dired buffer with turn-on-gnus-dired-mode
+
+If you don't mind keeping the mode on for all dired buffers, this should be enough:
+
+(use-package gnus-dired
+:hook (dired-mode . turn-on-gnus-dired-mode))
+
+You have the benefit of launching dired the same way you launch it for any other purpose (ie. easier to remember). No special binding.
+***** Deprecated Save All Function
+https://gist.github.com/philjackson/aecfab1706f05079aec7000e328fd183
+***** [#B] djcbsoftware.dl on attaching via dired
+https://www.djcbsoftware.nl/code/mu/mu4e/Dired.html
+13.9 Dired
+It is possible to attach files to mu4e messages using dired (emacs), using the following steps (based on a post on the mu-discuss mailing list by Stephen Eglen).
+
+(add-hook 'dired-mode-hook 'turn-on-gnus-dired-mode)
+Then, mark the file(s) in dired you would like to attach and press C-c RET C-a, and you’ll be asked whether to attach them to an existing message, or create a new one.
+***** [#B] djcbsoftware.dl on saving and comleting-all attachments
+
+Note: on hitting "e", then C-c C-a, it currently saves all attachments to the home directory. There's likely some directory setting I can use to choose a directory first (creating it if necessary).
+
+https://www.djcbsoftware.nl/code/mu/mu4e/MSGV-Attachments-and-MIME_002dparts.html
+5.4 Attachments and MIME-parts
+E-mail messages can be though as a series of “MIME-parts”, which are sections of the message. The most prominent is the ’body’, that is the main message your are reading. Many e-mail messages also contains attachments, which MIME-parts that contain files10.
+
+To save such attachments as files on your file systems, the mu4e message-view offers the command mu4e-view-save-attachments; default keybinding is e (think extract). After invoking the command, you can enter the file names to save, comma-separated, and using the completion support. Press RET to save the chosen files to your file-system.
+
+With a prefix argument, you get to choose the target-directory, otherwise, mu4e determines it following the variable mu4e-attachment-dir (which can be file-system path or a function; see its docstring for details.
+
+While completing, mu4e-view-completion-minor-mode is active, which offers mu4e-view-complete-all (bound to C-c C-a to complete all files11.
+*** TODO Org Contacts Integrated with Mu4e
+*** TODO Visit and Cancel Messages Not-yet-sent
+*** TODO Mail Queueing On By Default
+*** TODO Periodic Mail Fetch When Online
+*** TODO GPG Signed Emails
+*** 2024-04-04 Thu @ 16:47:12 -0500 Goals
+Not all email workflows are working (attachments, for instance).
+There are also some major longstanding bugs (not-yet-sent messages location)
+** TODO Calendaring Solution
+*** 2024-04-04 Thu @ 16:51:25 -0500 Current Requirements
+I'm starting from scratch, but here are my (currently simple) requirements
+- Download events from online calendar and include them in my agenda.
+- CRUD events in Emacs easy w/ propagation to online calendar
+ Agenda should be starting point, but it doesn't have to work from the Agenda pages.
+
+And yes, this means I also need to find and host an online calendar that sync's with an Android app.
+** TODO Ledger Workflow
+** TODO Emacs Config v0.8 Bug Fixes
+** TODO Emacs Config v0.8 Release Checklist [0/9]
+- [ ] No Open Work
+- [ ] WIP Code Empty/Disabled
+- [ ] Empty Emacs Config Inbox of Issues
+- [ ] Keep Sub-Second Launch Time
+- [ ] Successful Launch from Git Clone
+- [ ] Merged cleanly into main branch
+- [ ] Main Branch Pushed to github and git.cjennings.net
+- [ ] 2 Weeks of Use and Bug Fixing
+- [ ] Mark Release as DONE and Create Tag on Repo
+
+** TODO Consider the Flyspell Correct Ivy Interface for spelling
+#+BEGIN_QUOTE
+flyspell-correct-ivy interface
+In order to use flyspell-correct-ivy interface you have to install flyspell-correct-ivy package in any preferred way and then add following snippet to relevant part of your init.el file.
+
+(require 'flyspell-correct-ivy)
+(define-key flyspell-mode-map (kbd "C-;") 'flyspell-correct-wrapper)
+Or via use-package.
+
+(use-package flyspell-correct
+ :after flyspell
+ :bind (:map flyspell-mode-map ("C-;" . flyspell-correct-wrapper)))
+
+(use-package flyspell-correct-ivy
+ :after flyspell-correct)
+If you do not want any binding, just replace :bind (:map
+ flyspell-mode-map ("C-;" . flyspell-correct-wrapper)) with :defer t to use lazy loading.
+
+Note that in order to access actions in ivy interface you need to press M-o. More on ivy mini buffer key bindings you can read in official documentation.
+#+END_QUOTE
+[[https://github.com/d12frosted/flyspell-correct?tab=readme-ov-file#screenshots][d12frosted/flyspell-correct: Distraction-free words correction with flyspell via selected interface.]]
+Captured On: [2024-04-05 Fri 13:49]
+** TODO Consider Actively Developed Awesome Tray Instead of Unsupported Feebleline
+[[https://github.com/manateelazycat/awesome-tray?tab=readme-ov-file][manateelazycat/awesome-tray: Hide mode-line, display necessary information at right of minibuffer.]]
+Captured On: [2024-04-06 Sat 11:09]
+* Emacs Config v0.9
+** TODO VC Installs from Github
+** TODO Prog Go Workflow
+** TODO Prog Python Workflow
+** TODO Emacs Config v0.9 Release Checklist [0/9]
+- [ ] No Open Work
+- [ ] WIP Code Empty/Disabled
+- [ ] Empty Emacs Config Inbox of Issues
+- [ ] Keep Sub-Second Launch Time
+- [ ] Successful Launch from Git Clone
+- [ ] Merged cleanly into main branch
+- [ ] Main Branch Pushed to github and git.cjennings.net
+- [ ] 2 Weeks of Use and Bug Fixing
+- [ ] Mark Release as DONE and Create Tag on Repo
+* Emacs Config v0.10
+** TODO Complete "Localrepo" Functionality
+*** 2024-04-04 Thu @ 21:11:04 -0500 Considering Renaming "Localrepo"
+I worry that "localrepo" will be confused with elpa-mirrors, both local and remote.
+Also, I've named it what it is (it's local and a repo), not after its purpose.
+
+Naming it something like "last-known-good-packages" or "failsafe-packages" would:
+- avoid the confusion with elpa mirrors
+- avoid the confusion with version control repositories
+- make users hesitate before deleting the directory
+- make users understand it's purpose (and therefore it's importance)
+
+Candidate Names:
+- Last Known Good Pkgs
+- Failsafe Pkgs
+- Fallback Pkgs
+
+ChatGPT 4 came up with these names:
+- SafetyNetPkgs
+- StableVaultPkgs
+- TrustedBackupPkgs
+- SecureStandbyPkgs
+- BestCasePkgs
+- BufferZonePkgs
+- RevertReadyPkgs
+- SafeHarborPkgs
+- PackagePreserve
+- PkgSafeguard
+- StableShieldPkgs
+- PreparedPkgs
+- PkgLifeboat
+- BackupStashPkgs
+- AssuredAssetsPkgs
+- PkgPantry
+- RobustRepoPkgs
+- SafeSettlePkgs
+- ArchiveAnchorage
+- PkgFortress
+- DependableDepotPkgs
+- ReliableReservePkgs
+- HealthyHavenPkgs
+- PkgBunker
+- SolidStorePkgs
+- BulletproofBackupPkgs
+- PkgPlaza
+- SafeStoragePkgs
+- PkgCitadel
+- RescueRepoPkgs
+- ImmutableInstallPkgs
+- FortifiedFilesPkgs
+- ReviveReadyPkgs
+- PackagePillar
+- PlatinumPkgs
+
+The word "trusted" resonates with me, of course.
+
+*** 2024-04-04 Thu @ 20:59:43 -0500 Thoughts on Feature Set
+Functionality worth considering:
+**** update an installed package and update localrepo
+(package-and-localrepo-upgrade)
+though this one may not be desirable since the idea is to test packages by installing and using them first.
+**** update all installed packages and update localrepo
+(package-and-localrepo-upgrade-all)
+though this one may not be desirable since the idea is to test packages by installing and using them first.
+**** diff localrepo packages from the packages currently installed
+**** revert package to localrepo version
+this would amount to:
+- narrowing the package archives to localrepo
+- diffing localrepo and elpa to identify upgraded packages
+- showing all upgrading packages in completing read
+- uninstalling the selected package
+- reinstalling the selected package from localrepo
+- restarting emacs
+**** revert all packages to localrepo version
+this would amount to:
+- narrowing the package archives to localrepo
+- diffing localrepo and elpa to identify upgraded packages
+- showing all upgraded packages to confirm
+- uninstalling the upgraded packages
+- reinstalling the upgraded packages from localrepo
+- restarting emacs
+**** can you use git to save versions of these packages?
+** TODO Prog C Workflow
+** TODO Emacs Config v0.10 Release Checklist [0/9]
+- [ ] No Open Work
+- [ ] WIP Code Empty/Disabled
+- [ ] Empty Emacs Config Inbox of Issues
+- [ ] Keep Sub-Second Launch Time
+- [ ] Successful Launch from Git Clone
+- [ ] Merged cleanly into main branch
+- [ ] Main Branch Pushed to github and git.cjennings.net
+- [ ] 2 Weeks of Use and Bug Fixing
+- [ ] Mark Release as DONE and Create Tag on Repo
+* Emacs Config Backlog Categories
+** Emacs Browser Config Backlog [0/3]
+*** TODO Toggle Opening Links between External or Internal Browser Emacs-Wide
+**** 2023-07-29 @ 10:46:04 -0500 Code that seemed to work
+(defun my-eww-open-in-external-browser ()
+"Open the link at point in an external browser."
+(interactive)
+(let* ((url (eww-current-url))
+(browse-url-browser-function 'browse-url-default-browser))
+(when url
+(browse-url url))))
+
+(define-key eww-link-keymap (kbd "RET") 'my-eww-open-in-external-browser)
+```
+
+This revised code sets the `browse-url-browser-function` to `browse-url-default-browser`, which ensures that the URL is opened in the system's default external browser. It then opens the URL at point using `browse-url`. By binding the `RET` key to `my-eww-open-in-external-browser` in the `eww-link-keymap`, you should be able to open the link in an external browser.
+==================
+
+
+To toggle the ability to open links in an external browser in EWW, you can use the following Emacs Lisp code:
+
+```emacs-lisp
+(defvar my-eww-open-in-external-browser t
+"Toggle variable for opening links in an external browser in EWW.")
+
+(defun my-eww-toggle-open-in-external-browser ()
+"Toggle opening links in an external browser in EWW."
+(interactive)
+(setq my-eww-open-in-external-browser (not my-eww-open-in-external-browser))
+(if my-eww-open-in-external-browser
+(message "Links will now open in an external browser.")
+(message "Links will no longer open in an external browser.")))
+
+(defun my-eww-open-in-external-browser ()
+"Open the link at point in an external browser."
+(interactive)
+(when my-eww-open-in-external-browser
+(let* ((url (eww-current-url))
+(browse-url-browser-function 'browse-url-default-browser))
+(when url
+(browse-url url)))))
+
+(define-key eww-link-keymap (kbd "RET") 'my-eww-open-in-external-browser)
+```
+
+**** 2023-07-28 @ 10:06:17 -0500 playing with some ideas
+first attempts are in (user-emacs-directory)/modules/browser-toggle.el
+
+*** STALLED Working with the XWidget Webkit Browser
+**** 2024-04-03 Wed @ 15:23:54 -0500 XWidget Webkit no longer able to be built
+
+**** Original Goal
+[[https://emacsnotes.wordpress.com/2018/08/18/why-a-minimal-browser-when-there-is-a-full-featured-one-introducingxwidget-webkit-a-state-of-the-art-browser-for-your-modern-emacs/][Why a minimal browser, when there is a full-featured one? Introducing`XWidget Webkit`: A state-of-the-art browser for your modern Emacs – Emacs Notes]]
+Captured On: [2023-11-02 Thu 11:44]
+*** TODO Investigage shrface
+[[https://github.com/chenyanming/shrface][chenyanming/shrface: Extend eww/nov with org-mode features, archive web pages to org files with shr.]]
+Captured On: [2024-04-05 Fri 16:14]
+** Emacs Calibre / Epub Backlog [0/3]
+*** TODO Investigate Visual Fill Column for Ebooks
+[[https://melpa.org/#/visual-fill-column][visual-fill-column - MELPA]]
+Captured On: [2023-07-31 Mon 17:32]
+*** TODO Maybe Virtual Auto Fill for Ebooks?
+[[https://github.com/luisgerhorst/virtual-auto-fill/tree/a3991ce02d9a6a1624a3f04da80f4ac966a44092][luisgerhorst/virtual-auto-fill at a3991ce02d9a6a1624a3f04da80f4ac966a44092]]
+Captured On: [2023-07-31 Mon 17:36]
+*** TODO Pocket Reader to Epub Via Emacs
+[[https://blog.dornea.nu/2021/08/15/howto-convert-pocket-reader-links-to-epub-and-upload-to-dropbox/][HowTo: Convert pocket reader links to Epub and upload to Dropbox - blog.dornea.nu]]
+Captured On: [2023-10-21 Sat 08:43]
+** Emacs Config Utilities Backlog [0/1]
+*** TODO Test Emacs Config After Save
+#+BEGIN_QUOTE
+the Emacs Elements channel demonstrated emacs batch mode for checking your initialization. You can run something like
+
+emacs -batch -l ~/.emacs.d/init.el
+from a shell to start emacs, using the above initialization, and just immediately exit. If your configuration is bad, you'll see error messages about. And because it happens outside your existing emacs session, you can fix the errors inside emacs.
+
+But naturally we want to try that right from within emacs:
+
+(defun my-check-init-batch-mode ()
+"Use batch mode to check my emacs initialization.
+Inspired by https://www.youtube.com/watch?v=5Vume2SETNM."
+(interactive)
+(shell-command "emacs -batch -l ~/.emacs.d/init.el"))
+That's nice because, for me at least, I get lots of warnings, and it's nice to have the shell output buffer to look through and fix things up.
+
+I can confirm this works -- I added the above function to my config, ran it, then made a change from one of the warnings -- and made a typo in my lisp code, and fixed it right away. 🙂
+#+END_QUOTE
+[[https://emacs.stackexchange.com/questions/78945/run-check-parens-or-similar-when-saving-or-tangling-literate-configuration][org mode - run check-parens or similar when saving or tangling literate configuration? - Emacs Stack Exchange]]
+Captured On: [2023-11-18 Sat 08:10]
+** Emacs Dashboard Backlog [0/1]
+*** TODO Cookie 1 for Fortune Like Emacs Tips
+#+BEGIN_QUOTE
+It looks like cookie1.el is what I want: just point it to your file with
+
+(setq cookie-file "~/.emacs.d/emacs_tips.txt")
+or by customizing the variable. The format of the file is pretty simple -- it seems that the tips/quotes/fortunes are separated by lines with just % or %%:
+
+%
+Fortune cookie / emacs tip #1. Somehow this never shows up. *shrug*
+%
+Try M-r for moving point around the window without moving the text.
+%
+M-@ marks a word, use it repeatedly to mark more words.
+
+With a negative prefix arg, go backwards. Nice when combined with C-x C-x.
+%
+A numeric prefix argument X with M-< will move point to X% in the
+buffer. (Same thing with M-> moves to X% from the end.)
+%
+(Somehow the first entry is ignored; I tried some variations but it never showed up.)
+
+Then show one of those entries with M-x cookie.
+
+Above are the first few things I have. I plan to troll through the weekly tips and tricks threads and see what I find.
+#+END_QUOTE
+[[https://www.reddit.com/r/emacs/comments/17nvwnd/comment/k7xny8r/?utm_source=share&utm_medium=web2x&context=3][(2) emacs package or command to show a "tip/trick of the day"? : emacs]]
+Captured On: [2023-11-18 Sat 07:28]
+** Emacs Dirvish Backlog [0/3]
+*** TODO Add Find-dired (or Fd-dired) to Emacs
+[[https://www.masteringemacs.org/article/working-multiple-files-dired][Working with multiple files in dired - Mastering Emacs]]
+Captured On: [2023-07-31 Mon 16:36]
+*** TODO Enable/Disable Highlight Changes Mode When Entering/Exiting Wdired-mode
+#+BEGIN_QUOTE
+Excellent idea, here's how you enable and disable highlight-changes-mode automatically when entering and exiting wdired-mode:
+
+(defvar my/wdired-before-finish-editing-hook nil)
+
+(defun my/wdired-before-finish-editing-run-hook (&rest _)
+(run-hooks 'my/wdired-before-finish-editing-hook))
+
+(advice-add #'wdired-finish-edit :before #'my/wdired-before-finish-editing-run-hook)
+(advice-add #'wdired-abort-changes :before #'my/wdired-before-finish-editing-run-hook)
+
+
+(add-hook 'wdired-mode-hook (defun my/lambda-1693716265 ()
+(highlight-changes-mode 1)))
+
+(add-hook 'my/wdired-before-finish-editing-hook (defun my/lambda-1693716255 ()
+(highlight-changes-mode -1)))
+#+END_QUOTE
+[[https://www.reddit.com/r/emacs/comments/1658md9/weekly_tips_tricks_c_thread/][(2) Weekly Tips, Tricks, &c. Thread : emacs]]
+Captured On: [2023-11-18 Sat 08:06]
+*** TODO Dired Config with Sorting
+#+BEGIN_QUOTE
+(use-package dired
+ :bind (
+ :map dired-mode-map
+ ("C-a" . my/dired-move-beginning-of-line)
+ ("k" . dired-do-delete)
+ ("D" . nil)
+ ("s" . cc/dired-sort-by))
+ :hook (dired-mode . dired-hide-details-mode)
+ :init
+ (progn
+ (setq dired-auto-revert-buffer t)
+ (setq dired-dwim-target t)
+ (setq dired-listing-switches "-alh")
+ (setq dired-recursive-deletes 'always)
+ (setq dired-mouse-drag-files t)
+
+ (defun my/dired-move-beginning-of-line ()
+ (interactive)
+ (let ((point (point)))
+ (dired-move-to-filename)
+ (when (= point (point))
+ (move-beginning-of-line nil)))))
+ :config
+ (progn
+ ;; http://yummymelon.com/devnull/enhancing-dired-sorting-with-transient.html
+ (defun cc/--dired-sort-by (criteria &optional prefix-args)
+ "Sort current Dired buffer according to CRITERIA and PREFIX-ARGS.
+
+This function will invoke `dired-sort-other' with arguments built from
+CRITERIA and PREFIX-ARGS.
+
+CRITERIA is a keyword of which the following are supported:
+ :name :date-added :version
+ :kind :date-metadata-changed :size
+ :date-last-opened :date-modified
+
+PREFIX-ARGS is a list of GNU ls arguments. If nil, then it will use the value
+of `cc-dired-listing-switches'. Otherwise this is typically populated by the
+Transient menu `cc/dired-sort-by'.
+
+This function requires GNU ls from coreutils installed.
+
+See the man page `ls(1)' for details."
+ (let ((arg-list (list "-l")))
+ (if prefix-args
+ (nconc arg-list prefix-args)
+ (nconc arg-list cc-dired-listing-switches))
+ (cond
+ ((eq criteria :name)
+ (message "Sorted by name"))
+
+ ((eq criteria :kind)
+ (message "Sorted by kind")
+ (push "--sort=extension" arg-list))
+
+ ((eq criteria :date-last-opened)
+ (message "Sorted by date last opened")
+ (push "--sort=time" arg-list)
+ (push "--time=access" arg-list))
+
+ ((eq criteria :date-added)
+ (message "Sorted by date added")
+ (push "--sort=time" arg-list)
+ (push "--time=creation" arg-list))
+
+ ((eq criteria :date-modified)
+ (message "Sorted by date modified")
+ (push "--sort=time" arg-list)
+ (push "--time=modification" arg-list))
+
+ ((eq criteria :date-metadata-changed)
+ (message "Sorted by date metadata changed")
+ (push "--sort=time" arg-list)
+ (push "--time=status" arg-list))
+
+ ((eq criteria :version)
+ (message "Sorted by version")
+ (push "--sort=version" arg-list))
+
+ ((eq criteria :size)
+ (message "Sorted by size")
+ (push "-S" arg-list))
+
+ (t
+ (message "Default sorted by name")))
+
+ (dired-sort-other (mapconcat 'identity arg-list " "))))
+
+ (require 'transient)
+ (transient-define-prefix cc/dired-sort-by ()
+ "Transient menu to sort Dired buffer by different criteria.
+
+This function requires GNU ls from coreutils installed."
+ :value '("--human-readable"
+ "--group-directories-first"
+ "--time-style=long-iso")
+ ; TODO: support cc-dired-listing-switches
+ [["Arguments"
+ ("-a" "all" "--all")
+ ("g" "group directories first" "--group-directories-first")
+ ("-r" "reverse" "--reverse")
+ ("-h" "human readable" "--human-readable")
+ ("t" "time style" "--time-style="
+ :choices ("full-iso" "long-iso" "iso" "locale"))]
+
+ ["Sort By"
+ ("n"
+ "Name"
+ (lambda () (interactive)
+ (cc/--dired-sort-by :name
+ (transient-args transient-current-command)))
+ :transient nil)
+ ("k"
+ "Kind"
+ (lambda () (interactive)
+ (cc/--dired-sort-by :kind
+ (transient-args transient-current-command)))
+ :transient nil)
+ ("l"
+ "Date Last Opened"
+ (lambda () (interactive)
+ (cc/--dired-sort-by :date-last-opened
+ (transient-args transient-current-command)))
+ :transient nil)
+ ("a"
+ "Date Added"
+ (lambda () (interactive)
+ (cc/--dired-sort-by :date-added
+ (transient-args transient-current-command)))
+ :transient nil)
+ ("m"
+ "Date Modified"
+ (lambda () (interactive)
+ (cc/--dired-sort-by :date-modified
+ (transient-args transient-current-command)))
+ :transient nil)
+ ("M"
+ "Date Metadata Changed"
+ (lambda () (interactive)
+ (cc/--dired-sort-by :date-metadata-changed
+ (transient-args transient-current-command)))
+ :transient nil)
+ ("v"
+ "Version"
+ (lambda () (interactive)
+ (cc/--dired-sort-by :version
+ (transient-args transient-current-command)))
+ :transient nil)
+ ("s"
+ "Size"
+ (lambda () (interactive)
+ (cc/--dired-sort-by :size
+ (transient-args transient-current-command)))
+ :transient nil)]])))
+#+END_QUOTE
+[[https://github.com/DamienCassou/emacs.d/blob/master/init.el#L352][emacs.d/init.el at master · DamienCassou/emacs.d]]
+Captured On: [2024-04-05 Fri 15:15]
+** Emacs Ediff Backlog [0/2]
+*** TODO Improve Ediff Configuration
+#+BEGIN_QUOTE
+I also found that ediff has numerous hooks over its functions and I try to make ediff a little handy over window operations. What I want is a window-configuration restore after ediff exits, so I will have window layout just as before ediff, also I want easily to restore ediff window layout after I break it (for example switch to other buffer in one of diffed window). So we get:
+
+;; Some custom configuration to ediff
+(defvar my-ediff-bwin-config nil "Window configuration before ediff.")
+(defcustom my-ediff-bwin-reg ?b
+"*Register to be set up to hold `my-ediff-bwin-config'
+configuration.")
+
+(defvar my-ediff-awin-config nil "Window configuration after ediff.")
+(defcustom my-ediff-awin-reg ?e
+"*Register to be used to hold `my-ediff-awin-config' window
+configuration.")
+
+(defun my-ediff-bsh ()
+"Function to be called before any buffers or window setup for
+ediff."
+(setq my-ediff-bwin-config (current-window-configuration))
+(when (characterp my-ediff-bwin-reg)
+(set-register my-ediff-bwin-reg
+(list my-ediff-bwin-config (point-marker)))))
+
+(defun my-ediff-ash ()
+"Function to be called after buffers and window setup for ediff."
+(setq my-ediff-awin-config (current-window-configuration))
+(when (characterp my-ediff-awin-reg)
+(set-register my-ediff-awin-reg
+(list my-ediff-awin-config (point-marker)))))
+
+(defun my-ediff-qh ()
+"Function to be called when ediff quits."
+(when my-ediff-bwin-config
+(set-window-configuration my-ediff-bwin-config)))
+
+(add-hook 'ediff-before-setup-hook 'my-ediff-bsh)
+(add-hook 'ediff-after-setup-windows-hook 'my-ediff-ash 'append)
+(add-hook 'ediff-quit-hook 'my-ediff-qh)
+This kind of configuration will do the following. WindowConfiguration before any ediff operations will be saved to a register defined in my-ediff-bwin-reg and window configuration after ediff complete on window layout will be saved to my-ediff-awin-reg, so in ediff mode you may restore the old window configuration by jumping to my-ediff-bwin-reg and jump back to ediff window configuration by jumping to my-ediff-awin-reg (see WindowConfiguration). After ediff quits, the old (before ediff) window configuration will be restored.
+#+END_QUOTE
+[[https://www.emacswiki.org/emacs/EdiffMode][EmacsWiki: Ediff Mode]]
+Captured On: [2023-10-22 Sun 02:34]
+*** TODO Ediff From the Command Line
+#+BEGIN_QUOTE
+From The Command Line
+bojohan wrote on gnu.emacs.help:
+
+(defun command-line-diff (switch)
+(let ((file1 (pop command-line-args-left))
+(file2 (pop command-line-args-left)))
+(ediff file1 file2)))
+
+(add-to-list 'command-switch-alist '("diff" . command-line-diff))
+
+;; Usage: emacs -diff file1 file2
+That version is nice, but it opens a new Emacs for every diff. If you do not want that then there were other suggestions on the list that instead uses GnuClient.
+
+With GNU Emacs 23.1.1 on Ubuntu 10.04, I was obliged to add a dash like below:
+
+(add-to-list 'command-switch-alist '("-diff" . command-line-diff))
+#+END_QUOTE
+[[https://www.emacswiki.org/emacs/EdiffMode][EmacsWiki: Ediff Mode]]
+Captured On: [2023-10-22 Sun 02:38]
+** Emacs Elfeed Backlog [0/6]
+*** TODO Document Elfeed Workflow in Comments
+*** TODO Elfeed Login to Site Suggestion From Skeeto
+#+BEGIN_QUOTE
+- SKEETO
+Assuming you're using the curl backend (you really should), you can rely on whatever features curl has for this, like netrc. For example, put your credentials in .netrc, then add "--netrc" to elfeed-curl-extra-arguments.
+
+- ALRABAN
+Thanks for the suggestion. I am using the curl backend. Does that work correctly with an encrypted .netrc? Last time I tried that with curl it didn't work, but that was (admittedly) years ago. It works fine with plaintext, but that's what I'm trying to avoid.
+
+In any case I'll give it a shot.
+#+END_QUOTE
+[[https://www.reddit.com/r/emacs/comments/8mcpd9/elegant_way_to_provide_encrypted_credentials_to/][(3) Elegant way to provide encrypted credentials to elfeed or elfeed-protocol? : emacs]]
+Captured On: [2023-10-30 Mon 10:49]
+*** TODO Make Your Rss Enjoyable in Elfeed
+[[https://tsdh.org/posts/2021-08-12-make-your-rss-enjoyable-in-feed-readers-such-as-elfeed.html][Make Your RSS Enjoyable in Feed Readers Such as Elfeed]]
+
+Note: This has article shows how to alter key
+
+**** Article
+Article Link: https://tsdh.org/posts/2021-08-12-make-your-rss-enjoyable-in-feed-readers-such-as-elfeed.html
+Captured On: [2022-09-07 Wed 15:06]
+
+
+Make your RSS enjoyable in feed readers such as elfeed
+published: 2021-08-12
+
+Yesterday Michael Eliachevitch (check out [[https://meliache.srht.site/][his blog]]) made me aware of the fact that [[https://www.tsdh.org/rss.xml][my RSS feed]] didn't contain the full postings but only excerpts, i.e., the first paragraph of each post. That means that if you read it with a feed reader such as [[https://github.com/skeeto/elfeed][elfeed]] (which I highly recommend!), you only can read that excerpt and have to visit the web page in order to read the complete post. (That might make sense if you have advertising on your page but I'm just happy if someone reads and likes one or another of my posts no matter how they consume it.)
+
+As it turns out, putting just an excerpt in the feed seems to be pretty much standard behavior. So better check your feed!
+
+In order to put your complete post content in the feed, you have to change
+
+<description>{{ .Summary | html }}</description>
+
+to
+
+<description>{{ .Content | html }}</description>
+
+in your RSS template in case you are using [[https://gohugo.io/][Hugo]]. If you are using [[https://cobalt-org.github.io/][cobalt]] like me, add
+
+default:
+# default value is "\n\n"
+excerpt_separator: ""
+
+to your _cobalt.yml.
+
+Make Elfeed use the secondary browser
+
+While we're at it: I read feeds using [[https://github.com/skeeto/elfeed][elfeed]] and don't want to leave emacs for reading complete posts in case the feed has only an excerpts. At least, there's [[https://www.gnu.org/software/emacs/manual/html_node/eww/index.html#Top][EWW, the Emacs Web Wowser]].
+
+To read the rss contents, you just hit RET. In order to browse the post's web page, you hit b (elfeed-search-browse-url) which opens the page with browse-url-browser-function. If hit with prefix arg (C-u), it'll instead invoke the function bound to browse-url-generic.
+
+Normally, clicking an URL in emacs should call browse-url-button-open-url which usually calls browse-url-browser-function (browse-url-firefox for me), or, if a prefix arg is given, calls browse-url-secondary-browser-function (which I've set to eww). That's a convention used in vanilla emacs and other packages and I wish that elfeed conforms! So here's the .emacs snippet for doing so:
+
+#+begin_src emacs-lisp
+ (defun th/elfeed-search-browse-url-maybe-with-scndry-browser
+ (orig-fn &rest args)
+ (cl-letf (((symbol-function 'browse-url-generic) #'browse-url-button-open-url))
+ (apply orig-fn args)))
+
+ (advice-add
+ 'elfeed-search-browse-url
+ :around
+ #'th/elfeed-search-browse-url-maybe-with-scndry-browser
+ '((name "Make browse-url-generic call browse-url-button-open-url")))
+#+end_src
+
+What doas that do? Well, it makes browse-url-button-open-url the function in the function slot of the symbol browse-url-generic during calls of elfeed-search-browse-url, i.e., when elfeed-search-browse-url calls browse-url-generic it'll actually call browse-url-button-open-url.
+
+So now I can hit b in elfeed to open a posting in firefox and C-u b will open it in EWW. Ah, what a relief!
+
+EDIT: 2021-08-13: Michael Eliachevitch just made me aware that this advice should also be added to elfeed-show-visit which gets called with b from inside an elfeed buffer that already shows the RSS description of a posting. So that would be:
+
+#+begin_src emacs-lisp
+ (advice-add
+ 'elfeed-show-visit :around
+ #'th/elfeed-search-browse-url-maybe-with-scndry-browser
+ '((name "Make browse-url-generic call browse-url-button-open-url")))
+#+end_src
+
+Works like a charm. Thanks Michael!
+
+*** TODO More Elfeed Ideas
+[[https://blog.dornea.nu/2022/06/29/rss/atom-emacs-and-elfeed/][RSS/Atom, Emacs and elfeed - blog.dornea.nu]]
+Captured On: [2023-10-21 Sat 08:50]
+*** TODO RSS and Emacs
+[[https://blog.dornea.nu/2022/06/13/rss-and-atom-for-digital-minimalists/][RSS and Atom for digital minimalists - blog.dornea.nu]]
+Captured On: [2023-10-21 Sat 08:47]
+*** TODO Web-clip an Elfeed Entry Via a Single Keybinding
+also consider an immediate refile
+also consider moving the contents to an org-roam entry, asking for the title.
+** Emacs ERC Backlog [0/1]
+*** TODO Fix Gist Creation on Paste > 5 Lines in ERC
+** Emacs Eshell / Vterm / EAT Backlog [0/11]
+*** TODO Check Into Multi-vterm
+[[https://github.com/suonlight/multi-vterm][suonlight/multi-vterm: Managing multiple vterm buffers in Emacs]]
+Captured On: [2023-07-16 Sun 07:46]
+*** TODO Get Remote Connections Working From Eshell
+The following two servers should work without error and with tolerable speed.
+Currently, they will hang/freeze Emacs in an apparent loop (reentrant Tramp issues)
+- cd /sshx:cjennings@obelisk.usbx.me:/home/cjennings
+- cd /sshx:cjennings@cjennings.net:/var/cjennings
+*** TODO Look Into Eat.el for Terminal Usage
+[[https://codeberg.org/akib/emacs-eat/][akib/emacs-eat: Emulate A Terminal, in a region, in a buffer and in Eshell - Codeberg.org]]
+Captured On: [2024-03-17 Sun 00:43]
+*** TODO Look Into Eat With Eshell
+
+https://www.reddit.com/r/emacs/comments/17a628r/using_eat_eshell/
+Eat-eshell-mode turns the eshell buffer itself into an eat terminal. Since top is in eshell-visual-commands list, it gets run in a separate term mode buffer. To switch this out for an eat buffer, use eat-eshell-visual-command-mode.
+
+(use-package eat
+:custom
+(eat-term-name "xterm")
+:custom-face
+(ansi-color-bright-blue ((t (:foreground "#00afff" :background "#00afff"))))
+:config
+(evil-set-initial-state 'eat-mode 'emacs)
+(eat-eshell-mode)
+(eat-eshell-visual-command-mode))
+
+also... you can set eat-term-name to xterm-256color and don't worry about the colors
+
+[[https://codeberg.org/akib/emacs-eat][akib/emacs-eat: Emulate A Terminal, in a region, in a buffer and in Eshell - Codeberg.org]]
+Captured On: [2024-03-27 Wed 14:15]
+*** TODO Look Into This Vterm Workflow
+#+BEGIN_QUOTE
+My configs are not public currently, but I'm a migrant from vim so I have a "leader" key which all of my keybindings are under. Currently this is implemented through Transient. I have it bound to ,, and then all hotkeys build off that kinda like spacemacs or doom. , n will toggle the last vterm window with vterm-toggle, , i is a new transient for my work stuff, , i s is a second new transient for my work server, and finally , i s s will launch the work server. All of my other keybindings are like that too. I have a few helper functions to run a command in a new vterm buffer, and then I bind those commands to the transient. You can also get fancy with passing arguments, which I do for my work server. Apologies, but I'd rather not share that setup, but I did learn it mostly from reading the magit code. I can share some of the other helper functions.
+
+(defun jg/new-or-existing-vterm (buffer-name)
+"Open an existing buffer or create one with the BUFFER-NAME given."
+(or (get-buffer buffer-name) (vterm buffer-name)))
+
+(defun jg/vterm-send-command (command)
+"Sends COMMAND to a REPL running in vterm."
+(vterm-send-string command)
+(vterm-send-return))
+I would then use this like so:
+
+(defun jg/tuple ()
+(interactive)
+(with-current-buffer (jg/new-or-existing-vterm "*tuple*")
+(jg/vterm-send-command "flatpak run app.tuple.app")))
+Then I bind this jg/tuple function to the transient, and now I have it as a hotkey.
+#+END_QUOTE
+[[https://www.reddit.com/r/emacs/comments/104ud8k/how_do_you_use_the_terminal_during_a_coding/][(1) How do you use the terminal during a coding session? : emacs]]
+Captured On: [2024-03-27 Wed 14:29]
+*** TODO Make Eshell Command Open New Eshell Instead of Reusing Existing
+(defun buffer-exists (bufname)
+(not (eq nil (get-buffer bufname))))
+
+(defun make-shell (name)
+"Create a shell buffer named NAME."
+(interactive "sName: ")
+(if (buffer-exists "*eshell*")
+(setq eshell-buffer-name name)
+(message "eshell doesn't exist; using the default name: *eshell*"))
+(eshell))
+
+or
+
+(defun make-shell (name)
+"Create a shell buffer named NAME."
+(interactive "sName: ")
+(setq name (concat "$" name))
+(eshell)
+(rename-buffer name))
+
+https://stackoverflow.com/questions/2540997/create-more-than-one-eshell-instance-in-emacs
+*** TODO Verify Ability to Call Dired From Tramp / Eshell on Remote Server
+could happen either in minibuffer or eshell
+*** TODO Workflow Test: Use Elisp Function on Files in Directory
+https://www.masteringemacs.org/article/complete-guide-mastering-eshell
+https://www.reddit.com/r/emacs/comments/k5zrlb/somehow_eshell_is_working_perfectly/
+https://github.com/dieggsy/esh-autosuggest#esh-autosuggest
+https://emacs.stackexchange.com/questions/59862/unable-to-find-files-with-ssh-and-environment-variables
+https://github.com/emacs-jupyter/jupyter/issues/172
+*** TODO Look into eshell prompt extras to help your eshell prompt
+[[https://github.com/zwild/eshell-prompt-extras][zwild/eshell-prompt-extras: Display extra information and color for your eshell prompt.]]
+Captured On: [2024-04-05 Fri 07:15]
+*** TODO Look into implementing function to jump to directories in Emacs + Eshell
+[[https://karthinks.com/software/jumping-directories-in-eshell/][Jumping directories in eshell | Karthinks]]
+Captured On: [2024-04-02 Tue 09:28]
+*** TODO Review Mastering Eshell again for tips
+[[https://www.masteringemacs.org/article/complete-guide-mastering-eshell][Mastering Eshell - Mastering Emacs]]
+Captured On: [2024-04-05 Fri 07:22]
+** Emacs Flycheck Config Backlog [0/3]
+*** TODO Flycheck Hydra
+#+BEGIN_QUOTE
+Hydra / Flycheck
+Group Flycheck commands.
+
+(pretty-hydra-define hydra-flycheck
+(:hint nil :color teal :quit-key "q" :title (with-faicon "plane" "Flycheck" 1 -0.05))
+("Checker"
+(("?" flycheck-describe-checker "describe")
+("d" flycheck-disable-checker "disable")
+("m" flycheck-mode "mode")
+("s" flycheck-select-checker "select"))
+"Errors"
+(("<" flycheck-previous-error "previous" :color pink)
+(">" flycheck-next-error "next" :color pink)
+("f" flycheck-buffer "check")
+("l" flycheck-list-errors "list"))
+"Other"
+(("M" flycheck-manual "manual")
+("v" flycheck-verify-setup "verify setup"))))
+#+END_QUOTE
+[[https://github.com/rememberYou/.emacs.d/blob/master/config.org][.emacs.d/config.org at master · rememberYou/.emacs.d]]
+Captured On: [2023-11-19 Sun 17:24]
+*** TODO Flycheck Show Diagnostics Tip
+#+BEGIN_QUOTE
+with the latest flycheck (elpa):
+
+(setq flymake-show-diagnostics-at-end-of-line 'short)
+#+END_QUOTE
+[[https://www.reddit.com/r/emacs/comments/17vp0o1/weekly_tips_tricks_c_thread/][(2) Weekly Tips, Tricks, &c. Thread : emacs]]
+Captured On: [2023-11-18 Sat 07:19]
+*** TODO Make proselinting more visible to user when needed (org, text, md modes) in flycheck-config
+** Emacs Flyspell Config Backlog [0/3]
+*** TODO Nice Emacs Abbrevs Table
+#+BEGIN_QUOTE
+hellwolf_rt
+5 mo. ago
+I had fun generating abbrev_defs using chatgpt4: https://chat.openai.com/share/441c339e-1032-463d-afcb-9ca65f38d5e8
+
+(result at https://github.com/hellwolf/.emacs.d/blob/master/abbrev_defs)
+#+END_QUOTE
+[[https://www.reddit.com/r/emacs/comments/14l3jn8/weekly_tips_tricks_c_thread/][(2) Weekly Tips, Tricks, &c. Thread : emacs]]
+Captured On: [2023-11-18 Sat 08:59]
+*** TODO Fix Flyspell keybindings
+*** TODO removing flyspell keybindings should be placed with personal keymap definition
+** Emacs Font Config Backlog [0/10]
+*** TODO Emacs Emoji Tips
+#+BEGIN_QUOTE
+Step 2 is to ensure you have a font which supports emoji, and that font is used for emoji by your fontset. I did this with an Emacs lisp function:
+
+(defun init-my-font ()
+(set-face-font
+'default
+(font-spec
+:family "<your default font>"
+:size 10.3
+:weight 'normal
+:width 'normal
+:slant 'normal))
+(set-face-attribute 'default nil :height 103)
+;; emoji font
+(set-fontset-font
+t 'symbol
+(font-spec
+:family "Noto Color Emoji"
+:size 10.3
+:weight 'normal
+:width 'normal
+:slant 'normal))
+;; fallback font
+(set-fontset-font
+t nil
+(font-spec
+:family "DejaVu Sans Mono"
+:size 10.3
+:weight 'normal
+:width 'normal
+:slant 'normal)))
+If you use Emacs without a daemon, I think it is sufficient to call this function in your init file by writing (init-my-font). But I use a daemon and it seems to require that you wait until you have a gui frame before setting up the fonts. I have this hook for that:
+
+(add-hook
+'server-after-make-frame-hook
+(let (done)
+(lambda ()
+(unless done
+;; still set done to true even if we hit a bug (otherwise we
+;; can never open a frame to see the problem)
+(setq done t)
+(init-my-font)))))
+Note that this snippet requires lexical scoping in your init file.
+#+END_QUOTE
+[[https://emacs.stackexchange.com/questions/62219/how-do-i-get-colour-emoji-to-display-in-emacs][fonts - How do I get colour emoji to display in Emacs - Emacs Stack Exchange]]
+Captured On: [2023-11-04 Sat 17:55]
+*** TODO Examine Textsize Package
+[[https://github.com/WJCFerguson/textsize/tree/master][WJCFerguson/textsize: Emacs package textsize.el to automatically choose a font point size for the Emacs default face.]]
+Captured On: [2023-11-04 Sat 17:17]
+*** TODO Font Discussion
+[[https://emacs.stackexchange.com/questions/5689/force-a-single-font-for-all-unicode-glyphs][Force a single font for all unicode glyphs - Emacs Stack Exchange]]
+Captured On: [2023-11-04 Sat 17:27]
+*** TODO How to Use Bold on Some Font-lock Keywords
+#+BEGIN_QUOTE
+I liked the light version of JetBrainsMono and I like to use bold on some font-lock (keywords for example).
+
+(set-face-attribute 'default nil :font "JetBrainsMono Nerd Font Mono" :height 170 :weight 'light)
+(set-face-attribute 'fixed-pitch nil :font "JetBrainsMono Nerd Font Mono" :height 170 :weight 'light)
+(set-face-attribute 'variable-pitch nil :font "Iosevka Aile" :height 170 :weight 'light)
+(custom-set-faces '(font-lock-comment-face ((t (:font "Iosevka Aile" :italic t :height 1.0)))))
+#+END_QUOTE
+[[https://www.reddit.com/r/emacs/comments/13q0841/what_font_config_do_you_use_on_emacs/][(2) What font config do you use on emacs? : emacs]]
+Captured On: [2023-11-04 Sat 17:21]
+*** TODO Interesting Early-init.el Regarding Emacs Fonts
+[[https://github.com/Eason0210/.emacs.d/blob/master/early-init.el#L33-L82][.emacs.d/early-init.el at master · Eason0210/.emacs.d]]
+Captured On: [2023-11-04 Sat 17:22]
+*** TODO Look at Default-font-presets
+[[https://codeberg.org/ideasman42/emacs-default-font-presets][ideasman42/emacs-default-font-presets: Switch between a user defined list of fonts as well as scaling functionality. - emacs-default-font-presets - Codeberg.org]]
+Captured On: [2023-11-04 Sat 17:15]
+*** TODO New Emoji Support in Emacs 29
+#+BEGIN_QUOTE
+Nice. Maybe worth a mention is that Emacs 29 includes now it's own package to select (and preview) emojis.
+
+From the NEWS file:
+
+**** Emoji
+
++++
+***** Emacs now has several new methods for inserting Emojis.
+The Emoji commands are under the new 'C-x 8 e' prefix.
+
++++
+***** New command 'emoji-insert' (bound to 'C-x 8 e e' and 'C-x 8 e i').
+This command guides you through various Emoji categories and
+combinations in a graphical menu system.
+
++++
+***** New command 'emoji-search' (bound to 'C-x 8 e s').
+This command lets you search for Emojis based on names.
+
++++
+***** New command 'emoji-list' (bound to 'C-x 8 e l').
+This command lists all Emojis (categorized by themes) in a special
+buffer and lets you choose one of them.
+
+---
+***** New command 'emoji-recent' (bound to 'C-x 8 e r').
+This command lets you choose among the Emojis you have recently
+inserted.
+
++++
+***** New command 'emoji-describe' (bound to 'C-x 8 e d').
+This command will tell you the name of the Emoji at point. (This
+command also works for non-Emoji characters.)
+
+***** New input method 'emoji'.
+#+END_QUOTE
+[[https://www.reddit.com/r/emacs/comments/sufy5z/native_emojis_in_emacs/][(2) Native Emojis in Emacs : emacs]]
+Captured On: [2023-11-04 Sat 18:04]
+*** TODO Testing Unicode Tips
+#+BEGIN_QUOTE
+Step 1 is to make sure that you have Cairo and Harfbuzz enabled. You can run this elisp and check the results to test this:
+
+(featurep 'cairo) ; should evaluate to t
+(frame-parameter (selected-frame) 'font-backend) ; should be a list starting with ftcrhb
+#+END_QUOTE
+[[https://emacs.stackexchange.com/questions/62219/how-do-i-get-colour-emoji-to-display-in-emacs][fonts - How do I get colour emoji to display in Emacs - Emacs Stack Exchange]]
+Captured On: [2023-11-04 Sat 17:54]
+*** TODO Various Font-related Config
+[[https://www.reddit.com/r/emacs/comments/ll8mlz/share_your_fontrelated_config/][(2) Share your font-related config : emacs]]
+Captured On: [2023-11-04 Sat 17:24]
+*** TODO Review Interesting Modus Themes Settings for Ideas
+#+BEGIN_QUOTE
+(use-package modus-themes
+ :demand t
+ :init
+ (progn
+ (setq modus-themes-bold-constructs t)
+ (setq modus-themes-org-blocks 'greyscale)
+ (setq modus-themes-italic-constructs t)
+
+ (setq modus-themes-headings
+ '((1 . (1.6))
+ (2 . (background 1.5))
+ (3 . (background bold 1.2))
+ (4 . (1.1))
+ (t . ())))
+
+ (load-theme 'modus-operandi))
+ :config
+ (progn
+ (with-eval-after-load 'pdf-tools
+ ;; Configure PDF page colors. The code below comes from Modus
+ ;; Info manual (Backdrop for pdf-tools (DIY)).
+ (defun my/pdf-tools-backdrop ()
+ "Change background to be different from standard background."
+ (face-remap-add-relative
+ 'default
+ `(:background ,(modus-themes-color 'bg-alt))))
+
+ (defun my/pdf-tools-midnight-mode-toggle ()
+ "Change background of pdf-view-mode to adapt to current Modus theme."
+ (when (eq major-mode 'pdf-view-mode)
+ (if (eq (car custom-enabled-themes) 'modus-vivendi)
+ (pdf-view-midnight-minor-mode 1)
+ (pdf-view-midnight-minor-mode -1))
+ (my/pdf-tools-backdrop)))
+
+ (add-hook 'pdf-tools-enabled-hook #'my/pdf-tools-midnight-mode-toggle)
+ (add-hook 'modus-themes-after-load-theme-hook #'my/pdf-tools-midnight-mode-toggle))))
+#+END_QUOTE
+[[https://github.com/DamienCassou/emacs.d/blob/master/init.el#L352][emacs.d/init.el at master · DamienCassou/emacs.d]]
+Captured On: [2024-04-05 Fri 14:30]
+** Emacs Games Backlog [0/5]
+*** TODO Convert Alternate Chess Pieces Into Proper Format
+*** TODO Eradio Channels Should Leverage ~/music/*.m3u and *.pls Files
+should pull in m3u files in ~/music directory
+*** TODO Investigate Chess instability
+*** TODO Make Chess Display Colors Configurable
+;; map the following
+;; chess-display-retract
+
+;; LICHESS
+;; light squares: #F0D9B5
+;; dark squares: #B58863
+
+;; CHESS.COM
+;; light squares: #779556
+;; dark squares: #EBECD0
+*** TODO Make Chess Engine Selectable
+; do a completing-read with gnuchess, fruit, crafty, stockfish, etc.
+;; (ideally based on what's found on the system's path)
+
+** Emacs General Backlog [0/29]
+*** TODO Add Current Directory Into Load-path in Emacs
+#+BEGIN_QUOTE
+Add current directory into load-path in Emacs
+10 years ago   |   Source
+Tags :  elisp emacs en programming
+Useful when developing emacs plugin:
+
+(defun add-pwd-into-load-path ()
+"add current directory into load-path, useful for elisp developers"
+(interactive)
+(let ((dir (expand-file-name default-directory)))
+(if (not (memq dir load-path))
+(add-to-list 'load-path dir)
+)
+(message "Directory added into load-path:%s" dir)
+)
+)
+#+END_QUOTE
+[[https://blog.binchen.org/posts/add-current-directory-into-load-path-in-emacs/][Add current directory into load-path in Emacs | Chen's blog]]
+Captured On: [2024-01-09 Tue 16:09]
+*** TODO Check Out This Replace Workflow Using Ripgrep, Consult, Embark and Wgrep
+#+BEGIN_QUOTE
+I love the combination of consult, ripgrep, embark, and wgrep:
+
+recursive grep-as-you-type with consult-ripgrep
+
+then save that to a buffer with embark export
+
+then make that buffer writable with C-x C-q (wgrep)
+
+then edit the output of ripgrep
+
+then save those edits with C-c C-c
+
+For example, if I have a url http://example.com/ in a bunch of note files, I can ripgrep to find them all, then put that in a buffer, query-replace to change them all to http://anothersite.com/, then save them. It will go out to all the files where it was found and change the url.
+#+END_QUOTE
+[[https://www.reddit.com/r/emacs/comments/1benj4g/things_you_do_in_emacs_that_will_make_nonemacs/][(1) Things you do in Emacs that will make non-Emacs users go WOW? : emacs]]
+Captured On: [2024-03-24 Sun 16:47]
+*** TODO Consider Changing Emacs Kill Buffer to 'Kill Buffer and Delete Its Windows'
+#+BEGIN_QUOTE
+Kill Buffer and Delete Its Windows
+Command ‘kill-buffer-and-its-windows’, available in library Lisp:misc-cmds.el, kills the buffer and deletes all of its windows. The default buffer to kill is ‘current-buffer’. The argument to the command may be either a buffer or its name (a string).
+
+This command is especially useful as a replacement for command ‘kill-buffer’ when using Emacs Frames – see OneOnOneEmacs. Used with other frame-oriented functions, it also deletes the frame if the buffer is alone in the frame.
+
+Motivation:
+
+Command ‘kill-buffer’ displays a different buffer in the window, in place of one you’ve killed. With frames this is more annoying than useful.
+Command ‘kill-buffer-and-window’ just complains if you try to delete the sole window in a frame.
+Note: You can use ‘substitute-key-definition’ to replace all key bindings for ‘kill-buffer’ with bindings to ‘kill-buffer-and-its-windows’:
+
+(substitute-key-definition 'kill-buffer 'kill-buffer-and-its-windows global-map)
+#+END_QUOTE
+[[https://www.emacswiki.org/emacs/KillingBuffers#h5o-12][EmacsWiki: Killing Buffers]]
+Captured On: [2023-10-22 Sun 02:25]
+*** TODO Consider Literate DevOps
+[[https://howardism.org/Technical/Emacs/literate-devops.html][Literate DevOps]]
+Captured On: [2023-10-02 Mon 00:58]
+*** TODO Emacs Startup Tips
+#+BEGIN_QUOTE
+Tiny bootup speed tip: if you are on linux and use the gtk build of emacs, but you don't actually use any gtk stuff (menu, toolbar, scrollbar, etc. are hidden), then try the lucid build (or even, the "no" toolkit, --with-x-toolkit=no), emacs may boot up faster with it. On my pc, lucid build starts up ~150 msec faster than the gtk build.
+
+Another tip related to this: on my pc, non-gtk builds have an unnecessary wait during bootup. It turned out, emacs waits for some event from the X server, with the timeout of 0.1 sec. On my machine this makes bootup time 0.1 sec longer than it should be. I fixed this with (only one of these two is needed)
+
+(setq x-lax-frame-positioning t)
+(setq x-wait-for-event-timeout nil)
+
+in my early-init.el.
+
+Now, my fully configured emacs starts in 200 msec, which less than the stock gtk-build (emacs -Q).
+#+END_QUOTE
+[[https://www.reddit.com/r/emacs/comments/14377k9/weekly_tips_tricks_c_thread/][(2) Weekly Tips, Tricks, &c. Thread : emacs]]
+Captured On: [2023-11-18 Sat 08:41]
+*** TODO Fix Blocking Error "Key Sequence C-c M-g Starts With Non-prefix Key C-c Esc"
+**** TODO Grep source for keybinding for emacs C-c M-g boot error
+**** 2023-07-18 @ 15:05:01 -0500 Problem description and the fix that wasn't.
+I believe I may have fixed a longstanding issue with this emacs config where
+invoking projectile before the init had finished would cause it to produce this error:
+
+Error running timer ‘require’: (error "Key sequence C-c M-g starts with non-prefix key C-c ESC")
+
+I believe this was caused by a :bind statement in use-package where the bind statement
+had double-parenthesis, e.g.,
+:bind
+(("C-x g" . magit-status))
+became
+:bind
+("C-x g" . magit-status)
+
+After making the statement single-parenthesis, I can't reproduce the issue casually,
+so it's time to see if I can reproduce it intentionally/methodically.
+*** TODO Interesting Emacs Functions in Bashrc
+#+BEGIN_QUOTE
+emacs -nw is old, these days better to run emacs as deamon and connect through emacsclient, here is what I add to my .bashrc:
+
+# Emacs please
+if type emacs >/dev/null 2>/dev/null; then
+export ALTERNATE_EDITOR=""
+export VISUAL="emacsclient -c -a ''" # $VISUAL opens in GUI and waits
+export EDITOR="$VISUAL"
+
+function e() { emacsclient -c -a '' --eval "(progn (select-frame-set-input-focus (selected-frame)) (find-file \"$1\"))"; }
+function et() { emacsclient -t -a '' --eval "(progn (find-file \"$1\"))"; }
+function ediff() { emacsclient -c -a '' --eval "(progn (select-frame-set-input-focus (selected-frame)) (ediff-files \"$1\" \"$2\"))"; }
+function edired() { emacsclient -c -a '' --eval "(progn (select-frame-set-input-focus (selected-frame)) (dired \"$1\"))"; }
+function emagit() { emacsclient -c -a '' --eval "(progn (select-frame-set-input-focus (selected-frame)) (magit-status \"$1\"))"; }
+function ekill() { emacsclient --eval '(save-buffers-kill-emacs)'; }
+#+END_QUOTE
+[[https://www.reddit.com/r/emacs/comments/16w9bvh/using_emacs_as_editor/][(2) Using Emacs as $EDITOR : emacs]]
+Captured On: [2023-12-03 Sun 15:26]
+*** TODO Investigate Nand2tetris Emacs Mode
+[[https://github.com/CestDiego/nand2tetris.el/tree/master][CestDiego/nand2tetris.el: Major Mode for HDL files in nand2tetris.]]
+Captured On: [2023-10-02 Mon 00:31]
+*** TODO Look into Emacs Collaborative Editing Environment
+[[https://github.com/zaeph/crdt.el][zaeph/crdt.el]]
+Captured On: [2023-10-02 Mon 00:06]
+*** TODO Look into Philip Lord's Emacs Packages
+[[http://homepages.cs.ncl.ac.uk/phillip.lord/emacs.html][Emacs Packages]]
+Captured On: [2023-11-23 Thu 12:33]
+*** TODO Look Into Vmtouch for Emacs Speed
+https://blog.binchen.org/posts/emacs-speed-up-1000/
+[[https://github.com/hoytech/vmtouch/blob/master/vmtouch.pod][vmtouch/vmtouch.pod at master · hoytech/vmtouch]]
+Captured On: [2024-01-09 Tue 16:16]
+*** TODO Toggle full view of window in Emacs
+#+BEGIN_QUOTE
+
+Toggle full view of window in Emacs
+10 years ago   |   Source
+Tags :  emacs en
+Add below code into your ~/.emacs:
+
+
+(defun toggle-full-window()
+"Toggle the full view of selected window"
+(interactive)
+;; @see http://www.gnu.org/software/emacs/manual/html_node/elisp/Splitting-Windows.html
+(if (window-parent)
+(delete-other-windows)
+(winner-undo)
+))
+#+END_QUOTE
+[[https://blog.binchen.org/posts/toggle-full-view-of-window-in-emacs/][Toggle full view of window in Emacs | Chen's blog]]
+Captured On: [2024-01-09 Tue 16:12]
+*** TODO Update and Create File Headers in Emacs Lisp
+[[https://www.emacswiki.org/emacs/header2.el][EmacsWiki: header2.el]]
+Captured On: [2023-10-02 Mon 00:35]
+*** TODO Using Emacs as $EDITOR
+#+BEGIN_QUOTE
+30 Sep 2023
+
+Using Emacs as $EDITOR
+
+Continuing on from my experiment with using Emacs as for scrollback in my terminal multiplexer I thought I'd try to use it as my
+$EDITOR as well.
+
+The two main cases where I use $EDITOR is
+
+1 The occasional use of git on the command line, rebasing or writing a commit message, and
+2 Use of ZSH's edit-command-line functionality.
+
+To make sure Emacs is starting up quickly enough I'm using the same small setup I created for the scrollback editing, so I'm now
+setting EDITOR like this
+
+export EDITOR="emacs -nw --init-directory ~/.se.d"
+
+Now that I want to use the same setup for editing I can't really jump into view-mode every time Emacs starts so I have to be a bit
+more clever. The following bit won't do
+
+(add-hook 'find-file-hook #'view-mode)
+
+I need to somehow find out what starts Emacs and then only modify the hook when needed. Unfortunately I haven't found
+anything that reveals that Emacs is started by zellij. Creating a separate little script that zellij uses would be an option, of course,
+but for now I've opted to make it the default and instead refrain from adding the hook in the other two use cases.
+
+ZSH doesn't make it easy to find out that it's edit-command-line either, but as I've observed that the command line sometimes
+doesn't look right after leaving the editor I wanted to call redisplay to fix it up. That means I need to have a function anyway, so
+using an environment variable becomes an easy way to check if Emacs is being used to edit the command line.
+
+function se-edit-command-line() {
+export SE_SKIP_VIEW=y
+zle edit-command-line
+unset SE_SKIP_VIEW
+zle redisplay
+}
+zle -N se-edit-command-line
+
+bindkey -M vicmd '^V' se-edit-command-line
+bindkey -M viins '^V' se-edit-command-line
+
+Unfortunately is seems zle edit-command-line doesn't pass on non-exported environment variables, hence the explicit export and
+unset.
+
+When git starts an editor it sets a few environment variables so it was easy to just pick one that is set in both cases I care about. I
+picked GIT_EXEC_PATH.
+
+With these things in place I changed the slim setup to only add the hook when neither of the environment variables are present
+
+(unless (or (getenv "SE_SKIP_VIEW")
+(getenv "GIT_EXEC_PATH"))
+(add-hook 'find-file-hook #'view-mode))
+
+Hopefully this works out well enough that I won't feel a need to go back to using Neovim as my $EDITOR.
+
+Tags: emacs zsh
+Comment here.
+
+#+END_QUOTE
+[[https://magnus.therning.org/2023-09-30-using-emacs-as-$editor.html][Using Emacs as $EDITOR]]
+Captured On: [2023-10-11 Wed 21:42]
+*** TODO Look into MPDel for Music and Playlist Management
+[[https://github.com/mpdel/mpdel][mpdel/mpdel: Emacs user interface for MPD]]
+Captured On: [2024-04-05 Fri 14:05]
+*** TODO Research X-apply-session-resources Setting for Early Init
+#+BEGIN_QUOTE
+;; Ignore X resources; its settings would be redundant with the other settings
+;; in this file and can conflict with later config (particularly where the
+;; cursor color is concerned).
+(advice-add #'x-apply-session-resources :override #'ignore)
+#+END_QUOTE
+[[https://github.com/DamienCassou/emacs.d/blob/master/early-init.el][emacs.d/early-init.el at master · DamienCassou/emacs.d]]
+Captured On: [2024-04-05 Fri 14:12]
+*** TODO Deactivate Beeping in system-defaults.el
+#+BEGIN_QUOTE
+;; Deactivate beeping
+(setq ring-bell-function (lambda ()))
+#+END_QUOTE
+[[https://github.com/DamienCassou/emacs.d/blob/master/init.el][emacs.d/init.el at master · DamienCassou/emacs.d]]
+Captured On: [2024-04-05 Fri 14:14]
+*** TODO Investigate face-near-same-color-threshold setting for init.el
+#+BEGIN_QUOTE
+;; Apply recommendation from modus Info manual:
+(setq face-near-same-color-threshold 45000)
+#+END_QUOTE
+[[https://github.com/DamienCassou/emacs.d/blob/master/init.el][emacs.d/init.el at master · DamienCassou/emacs.d]]
+Captured On: [2024-04-05 Fri 14:14]
+*** TODO Consider this setting for more readable stacktraces
+#+BEGIN_QUOTE
+User Option: debugger-stack-frame-as-list ¶
+If this variable is non-nil, every stack frame of the backtrace is displayed as a list. This aims at improving the backtrace readability at the cost of special forms no longer being visually different from regular function calls.
+
+With debugger-stack-frame-as-list non-nil, the above example would look as follows:
+
+----------- Buffer: backtrace-output ------------
+ (backtrace)
+ (list 'testing (backtrace))
+ (progn ...)
+ (eval (progn (1+ var) (list 'testing (backtrace))))
+ (setq ...)
+ (save-excursion ...)
+ (let ...)
+ (with-output-to-temp-buffer ...)
+ (eval (with-output-to-temp-buffer ...))
+ (eval-last-sexp-1 nil)
+ (eval-last-sexp nil)
+ (call-interactively eval-last-sexp)
+----------- Buffer: backtrace-output ------------
+#+END_QUOTE
+[[https://www.gnu.org/software/emacs/manual/html_node/elisp/Internals-of-Debugger.html][Internals of Debugger (GNU Emacs Lisp Reference Manual)]]
+Captured On: [2024-04-05 Fri 14:20]
+*** TODO Print larger lists before abbreviating in edebug
+#+BEGIN_QUOTE
+(use-package edebug
+ :init
+ (setq edebug-print-length 5000))
+#+END_QUOTE
+[[https://github.com/DamienCassou/emacs.d/blob/master/init.el][emacs.d/init.el at master · DamienCassou/emacs.d]]
+Captured On: [2024-04-05 Fri 14:24]
+*** TODO Unify the Way Emacs Opens Files Across Packages
+[[https://github.com/DamienCassou/unify-opening][DamienCassou/unify-opening: Emacs package to make everything use the same mechanism to open files]]
+Captured On: [2024-04-05 Fri 15:28]
+*** TODO Evaluate saveplace mode for Emacs
+#+BEGIN_QUOTE
+(use-package saveplace
+ :demand t
+ :config
+ (progn
+ (save-place-mode)))
+#+END_QUOTE
+[[https://github.com/DamienCassou/emacs.d/blob/master/init.el#L352][emacs.d/init.el at master · DamienCassou/emacs.d]]
+Captured On: [2024-04-05 Fri 14:33]
+*** TODO Avy config for issuing other commands
+#+BEGIN_QUOTE
+(use-package avy
+ :bind* (("C-," . avy-goto-char-timer)
+ :map isearch-mode-map
+ ("C-," . avy-isearch))
+ :bind (("M-g g" . avy-goto-line))
+ :init
+ (progn
+ ;; home row on a Colemak keyboard:
+ (setq avy-keys '(?a ?r ?s ?t ?d ?h ?n ?e ?i ?o))
+ ;; Let me easily use actions beyond jump:
+ (setq avy-single-candidate-jump nil)
+ (setq avy-flyspell-correct-function #'ispell-word)
+ (setq avy-timeout-seconds 0.4))
+ :config
+ (progn
+ (defmacro my/avy-without-moving-point (point &rest body)
+ "Move point to POINT than execute BODY and restore previous location."
+ (declare (indent 1))
+ `(unwind-protect
+ (save-excursion
+ (goto-char point)
+ ,@body)
+ (select-window (cdr (ring-ref avy-ring 0)))))
+
+ (defun my/avy-action-help (point)
+ "Show the Emacs help for thing at POINT."
+ (my/avy-without-moving-point point
+ (helpful-at-point)))
+
+ (defun my/avy-action-kill-whole-line (point)
+ "Kill the whole line at POINT."
+ (my/avy-without-moving-point point
+ (kill-whole-line)))
+
+ (defun my/avy-action-embark (point)
+ "Start `embark-act' at POINT."
+ (my/avy-without-moving-point point
+ (embark-act)))
+
+ (setq avy-dispatch-alist
+ '(
+ ;; (?a) in avy-keys
+ ;; (?b)
+ ;; (?c)
+ ;; (?d) in avy-keys
+ ;; (?e) in avy-keys
+ ;; (?f)
+ ;; (?g)
+ ;; (?h) in avy-keys
+ ;; (?i) in avy-keys
+ ;; (?j)
+ ;; (?k)
+ ;; (?l)
+ ;; (?m)
+ ;; (?n) in avy-keys
+ ;; (?o) in avy-keys
+ ;; (?p)
+ ;; (?q)
+ ;; (?r) in avy-keys
+ ;; (?s) in avy-keys
+ ;; (?t) in avy-keys
+ ;; (?u)
+ ;; (?v)
+ ;; (?w)
+ ;; (?x)
+ ;; (?y)
+ ;; (?z)
+ ;; (?A)
+ ;; (?B)
+ ;; (?C)
+ ;; (?D)
+ ;; (?E)
+ ;; (?F)
+ ;; (?G)
+ ;; (?H)
+ ;; (?I)
+ ;; (?J)
+ ;; (?K)
+ ;; (?L)
+ ;; (?M)
+ ;; (?N)
+ ;; (?O)
+ ;; (?P)
+ ;; (?Q)
+ ;; (?R)
+ ;; (?S)
+ ;; (?T)
+ ;; (?U)
+ ;; (?V)
+ ;; (?W)
+ ;; (?X)
+ ;; (?Y)
+ ;; (?Z)
+ (?$ . avy-action-ispell)
+ (?? . my/avy-action-help)
+ (?\C-w . avy-action-kill-stay)
+ (?\C-k . my/avy-action-kill-whole-line)
+ (?\M-w . avy-action-copy)
+ (?\C-\S-a . my/avy-action-embark)))))
+#+END_QUOTE
+[[https://github.com/DamienCassou/emacs.d/blob/master/init.el#L352][emacs.d/init.el at master · DamienCassou/emacs.d]]
+Captured On: [2024-04-05 Fri 16:04]
+*** TODO Investigate auto-compile package
+#+BEGIN_QUOTE
+(use-package auto-compile
+ :demand t
+ :init
+ (progn
+ (setq auto-compile-display-buffer nil)
+ (setq auto-compile-source-recreate-deletes-dest t)
+ (setq auto-compile-toggle-deletes-nonlib-dest t)
+ (setq auto-compile-update-autoloads t))
+ :hook (auto-compile-inhibit-compile . auto-compile-inhibit-compile-detached-git-head)
+ :config
+ (progn
+ (auto-compile-on-load-mode)
+ (auto-compile-on-save-mode)
+ (auto-compile-use-mode-line-set nil nil)))
+
+#+END_QUOTE
+[[https://github.com/DamienCassou/emacs.d/blob/master/init.el][emacs.d/init.el at master · DamienCassou/emacs.d]]
+Captured On: [2024-04-05 Fri 14:16]
+*** TODO Investigate make executable if script
+Looks like it makes scripts executable on save
+#+BEGIN_QUOTE
+(use-package executable
+ :hook (after-save . executable-make-buffer-file-executable-if-script-p))
+#+END_QUOTE
+[[https://github.com/DamienCassou/emacs.d/blob/master/init.el][emacs.d/init.el at master · DamienCassou/emacs.d]]
+Captured On: [2024-04-05 Fri 14:25]
+*** TODO Investigate Drag-stuff to Replace Moving Regions Up/Down
+perhaps you can also move it across to a specific column?
+#+BEGIN_QUOTE
+(use-package drag-stuff
+ :demand t
+ :config
+ (progn
+ (drag-stuff-global-mode)
+ (drag-stuff-define-keys)
+ (dolist (mode '(org-mode rebase-mode emacs-lisp-mode mpdel-playlist-current-playlist-mode))
+ (add-to-list 'drag-stuff-except-modes mode))))
+#+END_QUOTE
+[[https://github.com/DamienCassou/emacs.d/blob/master/init.el#L352][emacs.d/init.el at master · DamienCassou/emacs.d]]
+Captured On: [2024-04-05 Fri 15:26]
+*** TODO Goggles eye-candy for modified region
+[[https://github.com/minad/goggles][minad/goggles: goggles.el - Pulse modified region]]
+Captured On: [2024-04-05 Fri 15:23]
+*** TODO Investigate runner for issuing common commands in dired
+[[https://github.com/thamer/runner][thamer/runner: Improved "open with" suggestions for dired mode in Emacs]]
+
+(use-package runner
+ :demand t
+ :after dired
+ :init
+ (progn
+ (setq runner-run-in-background t)))
+
+
+Captured On: [2024-04-05 Fri 15:16]
+*** TODO Investigate lin package for hl-highlighting
+#+BEGIN_QUOTE
+Package lin is available.
+
+ Status: Available from gnu-local -- Install
+ Archive: gnu-local
+ Version: 1.0.0
+ Commit: 09cf249c78385502a2ead30c4fa1468cf96939f7
+ Summary: Make `hl-line-mode' more suitable for selection UIs
+ Requires: emacs-27.1
+ Website: https://git.sr.ht/~protesilaos/lin
+ Keywords: convenience faces theme
+ Maintainer: Lin Development <~protesilaos/lin@lists.sr.ht>
+ Author: Protesilaos Stavrou <info@protesilaos.com>
+Other versions: 1.0.0 (gnu).
+
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━
+ LIN IS NOTICEABLE (LIN.EL)
+
+ Protesilaos Stavrou
+ info@protesilaos.com
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━
+
+
+This manual, written by Protesilaos Stavrou, describes the specifics of
+`lin.el'.
+
+The documentation furnished herein corresponds to stable version 1.0.0,
+released on 2022-09-08. Any reference to a newer feature which does not
+yet form part of the latest tagged commit, is explicitly marked as such.
+
+Current development target is 1.1.0-dev.
+
+⁃ Package name (GNU ELPA): `lin'
+⁃ Official manual: <https://protesilaos.com/emacs/lin>
+⁃ Change log: <https://protesilaos.com/emacs/lin-changelog>
+⁃ Git repo on SourceHut: <https://git.sr.ht/~protesilaos/lin>
+ • Mirrors:
+ ⁃ GitHub: <https://github.com/protesilaos/lin>
+ ⁃ GitLab: <https://gitlab.com/protesilaos/lin>
+⁃ Mailing list: <https://lists.sr.ht/~protesilaos/lin>
+
+Table of Contents
+─────────────────
+
+1. COPYING
+2. Overview LIN
+3. Installation
+.. 1. GNU ELPA package
+.. 2. Manual installation
+4. Sample configuration
+5. Acknowledgements
+6. GNU Free Documentation License
+7. Indices
+.. 1. Function index
+.. 2. Variable index
+.. 3. Concept index
+
+
+1 COPYING
+═════════
+
+ Copyright (C) 2021-2022 Free Software Foundation, Inc.
+
+ Permission is granted to copy, distribute and/or modify
+ this document under the terms of the GNU Free
+ Documentation License, Version 1.3 or any later version
+ published by the Free Software Foundation; with no
+ Invariant Sections, with the Front-Cover Texts being “A
+ GNU Manual,” and with the Back-Cover Texts as in (a)
+ below. A copy of the license is included in the section
+ entitled “GNU Free Documentation License.”
+
+ (a) The FSF’s Back-Cover Text is: “You have the freedom to
+ copy and modify this GNU manual.”
+
+
+2 Overview LIN
+══════════════
+
+ Lin is a stylistic enhancement for Emacs’ built-in `hl-line-mode'. It
+ remaps the `hl-line' face (or equivalent) buffer-locally to a style
+ that is optimal for major modes where line selection is the primary
+ mode of interaction.
+
+ The idea is that `hl-line-mode' cannot work equally well for contexts
+ with competing priorities: (i) line selection, or (ii) simple line
+ highlight. In the former case, the current line needs to be made
+ prominent because it carries a specific meaning of some significance
+ in the given context: the user has to select a line. Whereas in the
+ latter case, the primary mode of interaction does not revolve around
+ the line highlight itself: it may be because the focus is on editing
+ text or reading through the buffer’s contents, so the current line
+ highlight is more of a reminder of the point’s location on the
+ vertical axis.
+
+ `lin-mode' enables `hl-line-mode' in the current buffer and remaps the
+ appropriate face to the `lin-face'. The `lin-global-mode' follows the
+ same principle, though it applies to all hooks specified in the user
+ option `lin-mode-hooks'.
+
+ Users can select their preferred style by customizing the user option
+ `lin-face'. Options include the faces `lin-red', `lin-green',
+ `lin-yellow', `lin-blue' (default), `lin-magenta', `lin-cyan',
+ `lin-mac', `lin-red-override-fg', `lin-green-override-fg',
+ `lin-yellow-override-fg', `lin-blue-override-fg',
+ `lin-magenta-override-fg', `lin-cyan-override-fg',
+ `lin-mac-override-fg', or any other face that preferably has a
+ background attribute. The Lin faces with the `-override-fg' suffix
+ set a foreground value which replaces that of the underlying text.
+ Whereas the others only specify a background attribute.
+
+
+3 Installation
+══════════════
+
+
+
+
+3.1 GNU ELPA package
+────────────────────
+
+ The package is available as `lin'. Simply do:
+
+ ┌────
+ │ M-x package-refresh-contents
+ │ M-x package-install
+ └────
+
+
+ And search for it.
+
+ GNU ELPA provides the latest stable release. Those who prefer to
+ follow the development process in order to report bugs or suggest
+ changes, can use the version of the package from the GNU-devel ELPA
+ archive. Read:
+ <https://protesilaos.com/codelog/2022-05-13-emacs-elpa-devel/>.
+
+
+3.2 Manual installation
+───────────────────────
+
+ Assuming your Emacs files are found in `~/.emacs.d/', execute the
+ following commands in a shell prompt:
+
+ ┌────
+ │ cd ~/.emacs.d
+ │
+ │ # Create a directory for manually-installed packages
+ │ mkdir manual-packages
+ │
+ │ # Go to the new directory
+ │ cd manual-packages
+ │
+ │ # Clone this repo, naming it "lin"
+ │ git clone https://git.sr.ht/~protesilaos/lin lin
+ └────
+
+ Finally, in your `init.el' (or equivalent) evaluate this:
+
+ ┌────
+ │ ;; Make Elisp files in that directory available to the user.
+ │ (add-to-list 'load-path "~/.emacs.d/manual-packages/lin")
+ └────
+
+ Everything is in place to set up the package.
+
+
+4 Sample configuration
+══════════════════════
+
+ ┌────
+ │ (require 'lin)
+ │
+ │ (setq lin-face 'lin-blue) ; check doc string for alternative styles
+ │
+ │ ;; You can use this to live update the face:
+ │ ;;
+ │ ;; (customize-set-variable 'lin-face 'lin-green)
+ │
+ │ (setq lin-mode-hooks
+ │ '(bongo-mode-hook
+ │ dired-mode-hook
+ │ elfeed-search-mode-hook
+ │ git-rebase-mode-hook
+ │ grep-mode-hook
+ │ ibuffer-mode-hook
+ │ ilist-mode-hook
+ │ ledger-report-mode-hook
+ │ log-view-mode-hook
+ │ magit-log-mode-hook
+ │ mu4e-headers-mode
+ │ notmuch-search-mode-hook
+ │ notmuch-tree-mode-hook
+ │ occur-mode-hook
+ │ org-agenda-mode-hook
+ │ pdf-outline-buffer-mode-hook
+ │ proced-mode-hook
+ │ tabulated-list-mode-hook))
+ │
+ │ (lin-global-mode 1)
+ └────
+
+ Check out Christian Tietze’s blog post on integrating Lin with
+ Neotree: <https://christiantietze.de/posts/2022/03/hl-line-priority/>.
+
+
+5 Acknowledgements
+══════════════════
+
+ Lin is meant to be a collective effort. Every bit of help matters.
+
+ Author/maintainer
+ Protesilaos Stavrou.
+
+ Contributions to code or documentation
+ Christian Tietze, Damien Cassou, Federico Stilman, Gautier
+ Ponsinet, Kai von Fintel, Nicolas De Jaeghere.
+
+
+#+END_QUOTE
+[[help:Package][]]
+Captured On: [2024-04-05 Fri 14:43]
+** Emacs Help Config Backlog [0/1]
+*** TODO Remap keys from regular help to these instead of overwriting them in help-config
+** Emacs Host Environment Backlog [0/1]
+*** TODO Checking on Emacs Lisp to Identify Trackpoint
+[[https://emacs.stackexchange.com/questions/41349/use-mouse-buttons-as-modifiers][key bindings - Use mouse buttons as modifiers - Emacs Stack Exchange]]
+Captured On: [2023-12-02 Sat 23:21]
+** Emacs Hugo Config Backlog [0/3]
+*** TODO Good Read on Org-roam and Hugo / Ox-Hugo
+[[https://blog.dornea.nu/2022/10/04/migrate-tiddlywiki-to-org-roam-part-2-org-roam-and-hugo/][Migrate Tiddlywiki to org-roam - Part 2: org-roam and hugo - blog.dornea.nu]]
+Captured On: [2023-10-21 Sat 08:42]
+*** TODO Is Org-page Better Than Ox-hugo for Blogging?
+[[https://github.com/emacsorphanage/org-page][GitHub - emacsorphanage/org-page: [INACTIVE] A static site generator based on Emacs and org mode.]]
+Captured On: [2023-11-10 Fri 17:26]
+*** TODO Read the Ox Hugo Manual
+[[https://ox-hugo.scripter.co/][ox-hugo - Org to Hugo exporter]]
+Captured On: [2024-03-22 Fri 16:59]
+** Emacs Keybinding / Hydra / Transient Config Backlog [0/4]
+*** TODO Look at Pretty Hydra and Major Mode Hydra
+[[https://github.com/jerrypnz/major-mode-hydra.el/tree/5181a31631589ffd870f70293aeee00b7b773b58][GitHub - jerrypnz/major-mode-hydra.el at Pu5181a31631589ffd870f70293aeee00b7b773b58]]
+Captured On: [2023-12-06 Wed 13:27]
+*** TODO More Hydra Examples for Review
+[[https://github.com/abo-abo/hydra/blob/master/hydra-examples.el][hydra/hydra-examples.el at master · abo-abo/hydra]]
+Captured On: [2023-11-19 Sun 17:21]
+*** TODO Speedrect Quick key bindings and other tools for Emacs' rectangle-mark-mode.
+[[https://github.com/jdtsmith/speedrect][jdtsmith/speedrect: Quick key bindings and other tools for rectangle-mark-mode]]
+Captured On: [2023-10-27 Fri 11:09]
+*** TODO Using keyfreq to optimize keybindings
+[[https://blog.binchen.org/posts/how-to-be-extremely-efficient-in-emacs/][How to be extremely efficient in Emacs | Chen's blog]]
+Captured On: [2024-01-09 Tue 15:57]
+** Emacs Latex Config Backlog [0/3]
+*** TODO Good Latex Emacs Config
+[[https://michaelneuper.com/posts/efficient-latex-editing-with-emacs/][Efficient LaTeX Editing With Emacs - Michael]]
+Captured On: [2023-11-18 Sat 08:04]
+*** TODO Collapse graphviz config into the LaTeX Config or other suitable module
+*** TODO latex config
+[[https://gist.github.com/karthink/7d89df35ee9b7ac0c93d0177b862dadb][Configuration for super-fast Latex input using AucTeX, CDLatex and a bit of YaSnippet. See https://karthinks.com/software/latex-input-for-impatient-scholars]]
+Captured On: [2024-04-04 Thu 23:18]
+** Emacs Ledger Config Backlog [0/6]
+*** TODO Hydra for Ledger
+#+BEGIN_QUOTE
+Hydra / Ledger
+Group Ledger commands.
+
+(pretty-hydra-define hydra-ledger
+(:hint nil :color teal :quit-key "q" :title (with-faicon "usd" "Ledger" 1 -0.05))
+("Action"
+(("b" leadger-add-transaction "add")
+("c" ledger-mode-clean-buffer "clear")
+("i" ledger-copy-transaction-at-point "copy")
+("s" ledger-delete-current-transaction "delete")
+("r" ledger-report "report"))))
+#+END_QUOTE
+[[https://github.com/rememberYou/.emacs.d/blob/master/config.org][.emacs.d/config.org at master · rememberYou/.emacs.d]]
+Captured On: [2023-11-19 Sun 17:25]
+*** TODO Ledger-Mode Config to Review
+#+BEGIN_QUOTE
+Money Management
+Good money management is a skill to be acquired as soon as possible. Fortunately for us, Ledger allows you to have a double-entry accounting system directly from the UNIX command line. To use Ledger with GNU Emacs, you need to the ledger-mode package. However, do not forget to install the ledger package with your system package manager.
+
+I discovered Ledger as a student and learning how to manage time and expenses at the same time was too much. I decided for the time being to briefly learn Ledger and focus more on time management. One issue I had with Ledger was the lack of support from my bank to export my transactions into a file type that Ledger could understand. Unfortunately, since I often made bank transfers, encoding each payment by hand was a pain. For the curious people, alternatives to Ledger exist, some of which are open-source and proprietary (e.g., YNAB).
+
+NOTE: by default, Ledger uses the ISO 8601 format to write dates, which is the recommended format.
+
+(use-package ledger-mode
+:mode ("\\.\\(dat\\|ledger\\)\\'")
+:preface
+(defun my/ledger-save ()
+"Clean the ledger buffer at each save."
+(interactive)
+(ledger-mode-clean-buffer)
+(save-buffer))
+:bind (:map ledger-mode-map
+("C-x C-s" . my/ledger-save))
+:hook (ledger-mode . ledger-flymake-enable)
+:custom
+(ledger-clear-whole-transactions t)
+(ledger-reconcile-default-commodity "EUR")
+(ledger-reports
+'(("account statement" "%(binary) reg --real [[ledger-mode-flags]] -f %(ledger-file) ^%(account)")
+("balance sheet" "%(binary) --real [[ledger-mode-flags]] -f %(ledger-file) bal ^assets ^liabilities ^equity")
+("budget" "%(binary) --empty -S -T [[ledger-mode-flags]] -f %(ledger-file) bal ^assets:bank ^assets:receivables ^assets:cash ^assets:budget")
+("budget goals" "%(binary) --empty -S -T [[ledger-mode-flags]] -f %(ledger-file) bal ^assets:bank ^assets:receivables ^assets:cash ^assets:'budget goals'")
+("budget obligations" "%(binary) --empty -S -T [[ledger-mode-flags]] -f %(ledger-file) bal ^assets:bank ^assets:receivables ^assets:cash ^assets:'budget obligations'")
+("budget debts" "%(binary) --empty -S -T [[ledger-mode-flags]] -f %(ledger-file) bal ^assets:bank ^assets:receivables ^assets:cash ^assets:'budget debts'")
+("cleared" "%(binary) cleared [[ledger-mode-flags]] -f %(ledger-file)")
+("equity" "%(binary) --real [[ledger-mode-flags]] -f %(ledger-file) equity")
+("income statement" "%(binary) --invert --real -S -T [[ledger-mode-flags]] -f %(ledger-file) bal ^income ^expenses -p \"this month\""))
+(ledger-report-use-header-line nil)))
+Finally, to provides a flychecker checker for Ledger files, you can use flycheck-ledger.
+
+(use-package flycheck-ledger :after ledger-mode)
+#+END_QUOTE
+[[https://github.com/rememberYou/.emacs.d/blob/master/config.org][.emacs.d/config.org at master · rememberYou/.emacs.d]]
+Captured On: [2023-11-19 Sun 17:29]
+*** TODO Recording Ledger Entries With Org-capture-templates
+#+BEGIN_QUOTE
+Emacs: Recording ledger entries with org-capture-templates
+Posted: Nov 23, 2010 - Modified: May 27, 2014| emacs
+Updated 2014-05-26: Thanks to Greg for the updated link to https://github.com/ledger/ledger/wiki !
+I use John Wiegley's ledger program to keep track of my personal finances. It's quick, it's light, and it lets me slice-and-dice my data however I want. I enjoy opening my ledger file and adding transactions to it. (Particularly if it involves income!) Yes, I'm that kind of weird.
+
+I wanted to make it even easier to add entries. Instead of using C-x C-f to find the file, using ESC > to go to the end of the buffer, and typing in the transactions, I decided to add some of my common transactions to org-capture-templates. Here's the relevant snippet:
+
+(setq org-capture-templates
+(append '(("l" "Ledger entries")
+("lm" "MBNA" plain
+(file "~/personal/ledger")
+"%(org-read-date) %^{Payee}
+Liabilities:MBNA
+Expenses:%^{Account} %^{Amount}
+")
+("lc" "Cash" plain
+(file "~/personal/ledger")
+"%(org-read-date) * %^{Payee}
+Expenses:Cash
+Expenses:%^{Account} %^{Amount}
+"))
+org-capture-templates))
+I've bound org-capture to C-c r using (global-set-key (kbd "C-c r") 'org-capture), so now I can use C-c r l m to create an entry for my MBNA Mastercard. This keyboard shortcut might not seem short to you, but if you think about it as C-c remember ledger Mastercard, it makes perfect sense. =) (Besides, org-capture prompts me just in case I forget.)
+
+Hooray for org-capture!
+
+#+END_QUOTE
+[[https://sachachua.com/blog/tag/ledger/][tag - ledger :: Sacha Chua]]
+Captured On: [2023-11-18 Sat 07:11]
+*** TODO Using Flymake With Ledger
+#+BEGIN_QUOTE
+To use flymake with ledger in Emacs 26.1 or higher, just do:
+
+(add-hook 'ledger-mode-hook #'ledger-flymake-enable)
+#+END_QUOTE
+[[https://www.reddit.com/r/emacs/comments/8x4xtt/tip_how_i_use_ledger_to_track_my_money/][(2) TIP: How I use ledger to track my money : emacs]]
+Captured On: [2023-11-18 Sat 07:16]
+*** TODO Large Ledger Configuration
+#+BEGIN_QUOTE
+(use-package ledger-mode
+ :hook (ledger-mode . my/configure-ledger-mode)
+ :mode "\\.hledger\\'"
+ :bind (
+ :map ledger-mode-map
+ ("C-c C-r" . ledger-report)
+ ("C-c C-c" . my/ledger-lint)
+ ;; To get outline-minor-mode in ledger buffers:
+ ("TAB" . org-cycle)
+ :map ledger-report-mode-map
+ ("C-c C-r" . ledger-report))
+ :init
+ (progn
+ (setq ledger-reports
+ (mapcar
+ (lambda (pair)
+ (list (car pair)
+ (format "%s %s"
+ "%(binary) -f %(ledger-file)"
+ (cdr pair))))
+ '(("Account statement" . "register --ignore-assertions --auto ^%(account)")
+ ("Income statement" . "balance --ignore-assertions --auto --tree --period %(month) --invert ^income ^expense")
+ ("Balance sheet" . "balance --ignore-assertions --auto --tree ^asset ^debt \"^equity:\"")
+ ("Budget" . "balance --ignore-assertions --auto --tree --empty ^budget not:unbudgeted"))))
+
+ ;; For hledger
+ (progn
+ (setq ledger-mode-should-check-version nil)
+ (setq ledger-binary-path (executable-find "hledger"))
+ (setq ledger-report-links-in-register nil)
+ (setq ledger-report-native-highlighting-arguments '("--color=always"))
+ (setq ledger-report-auto-width nil))
+
+ (setq ledger-reconcile-default-commodity "EUR")
+ (setq ledger-report-use-header-line t)
+ (setq ledger-report-use-native-highlighting t)
+ (setq ledger-report-auto-refresh-sticky-cursor t)
+ (setq ledger-report-use-strict t)
+ (setq ledger-highlight-xact-under-point nil)
+ (setq ledger-copy-transaction-insert-blank-line-after t)
+
+ (defun my/ledger-configure-outline-minor-mode ()
+ "Configure a ledger buffer when `outline-minor-mode' is active."
+ (font-lock-add-keywords 'ledger-mode outline-font-lock-keywords)
+ (setq-local ;; copied from outline-mode major mode:
+ imenu-generic-expression
+ (list (list nil (concat "^\\(?:" outline-regexp "\\).*$") 0))))
+
+ (defun my/configure-ledger-mode ()
+ "Configure the current Ledger buffer."
+ ;; use TAB to complete:
+ (setq-local tab-always-indent 'complete)
+ (add-hook 'outline-minor-mode-hook #'my/ledger-configure-outline-minor-mode nil t)))
+ :config
+ (progn
+ (let ((date-format "%A, %B %-e"))
+ (defun my/ledger-position-at-date (moment)
+ "Move point in current buffer to insert new transaction at MOMENT.
+MOMENT is an encoded date."
+ (let ((heading (format "*** %s" (format-time-string date-format moment))))
+ (goto-char (point-min))
+ (search-forward heading)
+ (forward-line)
+ (re-search-forward "; \\*\\*\\*" nil t)
+ (goto-char (line-beginning-position)))))
+
+ (advice-add #'ledger-xact-find-slot :override #'my/ledger-position-at-date)
+
+ (defun my/ledger-lint ()
+ "Lint my ledger file."
+ (interactive)
+ (require 'autoclose-shell)
+ (save-buffer)
+ (autoclose-shell-start "lint-system" '("lint-system")))
+
+ (defun my/ledger-insert-mortgage-transaction ()
+ "Read accounting data for MORTGAGE and write the ledger entry."
+ (interactive)
+ (ensure-empty-lines 1)
+ (let* ((description (read-string "Description: "))
+ (date (ledger-read-date "Date: "))
+ (begining (point)))
+ (insert (format "%s %s\n" date description))
+ (insert (format " asset:current:couple 0\n"))
+ (insert (format " expense:misc 0\n"))
+ (save-excursion
+ (goto-char begining)
+ (my/ledger-mortgage-rewrite))))
+
+ (defun my/ledger-mortgage-read-numbers ()
+ "Returns the numbers of the current mortgage reimbursement transaction.
+
+The returned value is of the form (:capital CAPITAL :insurance INSURANCE :interest INTEREST)."
+ (cl-labels ((parse-number (string) (string-to-number (string-replace "," "." string))))
+ (let* ((number-regexp (rx (1+ (any digit)) ?, (1+ (any digit))))
+ (regexp (rx "ECHEANCE PRET"
+ (? " -")
+ " DONT CAP "
+ (group-n 1 (regexp number-regexp))
+ " ASS. "
+ (group-n 2 (regexp number-regexp))
+ "E"
+ (? " -")
+ " INT. "
+ (group-n 3 (regexp number-regexp))
+ (? " COM. 0,00E"))))
+ (save-match-data
+ (save-excursion
+ (ledger-navigate-beginning-of-xact)
+ (when-let* (((re-search-forward regexp (line-end-position)))
+ (capital (parse-number (match-string 1)))
+ (insurance (parse-number (match-string 2)))
+ (interest (parse-number (match-string 3))))
+ (list :capital capital :insurance insurance :interest interest)))))))
+
+ (defun my/ledger-mortgage-guess-type (numbers)
+ "Return the type of the transaction with NUMBERS.
+The type is either 'ecoptz, 'immo1 or 'immo2.
+
+NUMBERS is of the form (:capital CAPITAL :insurance INSURANCE :interest INTEREST)."
+ (cond
+ ((and (>= (map-elt numbers :insurance) 0.1)
+ (= (map-elt numbers :interest) 0))
+ 'ecoptz)
+ ((or (>= (map-elt numbers :insurance) 0.1)
+ (= (map-elt numbers :interest) 0))
+ (user-error "Invalid numbers: %S" numbers))
+ ((>= (map-elt numbers :capital) 700) 'immo1)
+ (t 'immo2)))
+
+ (defun my/ledger-mortgage-rewrite ()
+ "Rewrite the mortgage transaction at point."
+ (interactive)
+ (when-let* ((numbers (my/ledger-mortgage-read-numbers))
+ (total (seq-reduce
+ #'+
+ (map-values (my/ledger-mortgage-read-numbers))
+ 0))
+ (mortgage-type (my/ledger-mortgage-guess-type numbers)))
+ (save-match-data
+ (save-excursion
+ (ledger-navigate-beginning-of-xact)
+ (when (re-search-forward " .*$" (line-end-position)) ; skip date
+ (replace-match " banque populaire prêt" t)
+ (next-line)
+ (delete-region (line-beginning-position) (line-end-position))
+ (insert (format " asset:current:couple %.2f" (- total)))
+ (ledger-navigate-end-of-xact)
+ (delete-region (line-beginning-position) (line-end-position))
+ (map-do
+ (lambda (number-type number)
+ (when (> number 0)
+ (let ((account (if (eq number-type :insurance)
+ "expense:util:insurance"
+ (format "expense:mortgage:%s%s" mortgage-type number-type))))
+ (insert " " account " " (number-to-string number) "\n"))))
+ numbers)
+ (delete-backward-char 1) ; remove additional newline
+ (ledger-post-align-dwim))))))))
+
+(use-package flymake-hledger
+ :config
+ (progn
+ (setq flymake-hledger-command '("hledger" "--auto"))
+
+ ;; Enable 4 optional checks. See URL
+ ;; https://hledger.org/1.30/hledger.html#check for the meaning of
+ ;; each check and a list of all of them.
+ (dolist (check '("ordereddates" "payees" "recentassertions" "tags"))
+ (add-to-list 'flymake-hledger-checks check))))
+
+#+END_QUOTE
+[[https://github.com/DamienCassou/emacs.d/blob/master/init.el#L352][emacs.d/init.el at master · DamienCassou/emacs.d]]
+Captured On: [2024-04-05 Fri 15:21]
+*** TODO Ledger Import Config
+#+BEGIN_QUOTE
+(use-package ledger-complete
+ :init
+ (progn
+ (setq ledger-complete-in-steps nil)))
+
+(use-package ledger-import
+ :hook ((ledger-import-finished . my/ledger-import-finish))
+ :config
+ (progn
+ (setq ledger-import-boobank-import-from-date "2023-07-29")
+ (setq ledger-import-autosync-command
+ '("hledger-autosync" "--assertions"
+ "--payee-format" "{payee}"))
+
+ (defun my/ledger-import-alert ()
+ "Notify the user that import is finished."
+ (alert "Finished"
+ :title "Ledger-autosync"
+ :buffer (current-buffer)))
+
+ (defun my/ledger-import-remove-EUR ()
+ "Remove the EUR commodity in the current buffer."
+ (goto-char (point-min))
+ (while (search-forward " EUR" nil t)
+ (replace-match ""))
+ (ledger-mode-clean-buffer))
+
+ (defun my/ledger-import-merge-autosync-transactions ()
+ "Merge all autosync transactions into just one."
+ (goto-char (point-min))
+ (search-forward "Autosync Balance Assertion")
+ (delete-matching-lines "Autosync Balance Assertion")
+ (delete-matching-lines "^$"))
+
+ (defun my/ledger-import-add-today-date-as-outline ()
+ "Add today's date as `outline-mode' markup."
+ (goto-char (point-min))
+ (search-forward "Autosync Balance Assertion")
+ (goto-char (line-beginning-position))
+ (insert (format "*** %s\n\n" (format-time-string "%B %-d"))))
+
+ (defun my/ledger-import-finish ()
+ "Some actions to do when ledger-import finishes."
+ (interactive)
+ (my/ledger-import-remove-EUR)
+ (my/ledger-import-merge-autosync-transactions)
+ (my/ledger-import-add-today-date-as-outline)
+ (my/ledger-import-alert))
+
+ ;; Fill `ledger-import-accounts' and `ledger-import-ofx-rewrite-rules':
+ (let ((file (expand-file-name "~/.password-store/Secure_Notes/ledger-accounts.gpg")))
+ (when (file-exists-p file)
+ (load file t)))))
+#+END_QUOTE
+[[https://github.com/DamienCassou/emacs.d/blob/master/init.el#L352][emacs.d/init.el at master · DamienCassou/emacs.d]]
+Captured On: [2024-04-05 Fri 15:21]
+** Emacs Local Repository Backlog [0/1]
+*** TODO Finish Writing Local Repository as a Package
+
+;; - if first run or packages have been upgraded,
+;; - check constant on next action. options are:
+;; - notify user and update local repository
+;; - updtate local repository without asking
+;; - notify user and ask to update local repository
+;; - do nothing
+;; - function to update local repository with keybinding
+** Emacs Mail Backlog [0/20]
+*** TODO Allow for Mail Queueing in Both the Script and Emacs Config
+**** 2023-10-28 Sat @ 15:25:01 -0500 Direction
+- This should really be a toggled function, with the default always to be on at launch
+ This way if the user forgets that they're in queue mode, the user will automatically
+ send all emails next time they launch.
+- Also, I'd prefer for an icon to appear in the modeline when mail is being queued.
+ If I create a simple custom modeline, or the user is using a default modeline,
+ this is likely more straightforward than trying to write an extention to doom-modeline
+ and spaceline for instance.
+**** Reference in Manual
+https://www.djcbsoftware.nl/code/mu/mu4e/Queuing-mail.html
+**** Reference From Stackexchange
+https://emacs.stackexchange.com/questions/37344/how-to-queue-mail-to-send
+The mu4e manual node on queuing mail explains how to do this. Quoting the manual:
+
+If you cannot send mail right now, for example because you are currently offline, you can queue the mail, and send it when you have restored your internet connection. You can control this from the Main view.
+
+To allow for queuing, you need to tell smtpmail where you want to store the queued messages. For example:
+
+(setq smtpmail-queue-mail t ;; start in queuing mode
+
+smtpmail-queue-dir "~/Maildir/queue/cur")
+For convenience, we put the queue directory somewhere in our normal maildir. If you want to use queued mail, you should create this directory > before starting mu4e. The mu mkdir command may be useful here, so for example:
+
+$ mu mkdir ~/Maildir/queue
+
+$ touch ~/Maildir/queue/.noindex
+
+The file created by the touch command tells mu to ignore this directory for indexing, which makes sense since it contains smtpmail meta-data rather than normal messages; see the mu-mkdir and mu-index man-pages for details.
+
+Warning: when you switch on queued-mode, your messages won’t reach their > destination until you switch it off again; so, be careful not to do this accidentally!
+*** TODO Figure Out How to Filter/Categorize Mails Using Mu4e
+https://www.reddit.com/r/emacs/comments/202fon/email_filters_in_mu4e/
+*** TODO Figure Out Your Mail Attachments Workflow
+**** TODO [#C] The Mu4e Save Attachment Function to the Actions List Doesn't Work
+removed this from mu4e configuration
+;; (add-to-list 'mu4e-view-actions
+;; '("download attachments" . cj/mu4e-view-save-attachments))
+
+*** TODO Fix Org Capture Template for Contacts
+*** TODO GPG Signatures Working With Mu4e
+*** TODO Investigate this Mu4e and Emacs config
+[[https://200ok.ch/posts/2020-05-27_using_emacs_and_mu4e_for_emails_even_with_html.html][Using Emacs and mu4e for emails - even with HTML]]
+Captured On: [2023-10-22 Sun 01:28]
+*** TODO Set Incoming Emails as Read in Emacs Mu4e
+[[https://ag91.github.io/blog/2022/02/28/set-all-incoming-emails-as-read-with-mu4e/][Set all incoming emails as read with Mu4e - Where parallels cross]]
+Captured On: [2023-11-10 Fri 17:27]
+*** TODO Simple Keybinding to Display Attachments Leveraging Xdg-mime
+*** TODO Test Org-contacts Integration
+*** TODO Test This Mu4e Setting for HTML Emails
+#+BEGIN_QUOTE
+Disable MU4E 'HTML over plain text' heuristic
+2018-10-25 - 272 WORDS - 2 MIN READ
+
+
+Alain M. Lafon
+By default, the great Mail User Agent MU4E prefers Plain Text mails over HTML. This configuration can be overridden via mu4e-view-prefer-html, but there's probably few of us who would do that.
+
+However, you might still see a whole lot of HTML emails. And when you check if they have a plain text version, they might have one! There's a reason for that. MU4E has a 'HTML over plain text' heuristic with this official rationale:
+
+Ratio between the length of the html and the plain text part below which mu4e will consider the plain text part to be 'This messages requires html' text bodies. You can neutralize it (always show the text version) by using `most-positive-fixnum'.
+
+This heuristic overwrites the default setting (and configuration) that Plain text should be preferred over HTML!
+
+In my experience, HTML Emails are WAY longer than only 5x the Plain text (Doodle, Airbnb, Meetup, etc), so this will yield me a lot of false positives whereas I have never seen a "This message requires HTML" body. Since I realized that MU4E has this heuristic, I overrode it just like the doc string told me to and am an even happier MU4E user.
+
+(setq mu4e-view-html-plaintext-ratio-heuristic most-positive-fixnum)
+NB, if you want to be able to read HTML emails, that's totally and 100% supported within MU4E! You can render them as:
+
+Text within a regular Emacs buffer
+PDF within a regular Emacs buffer - complete with styles and all
+Open the email in a browser through a shortcut
+
+#+END_QUOTE
+[[https://200ok.ch/posts/2018-10-25_disable_mu4e_html_over_plain_text_heuristic.html][Disable MU4E 'HTML over plain text' heuristic]]
+Captured On: [2023-10-22 Sun 01:27]
+*** TODO Ability to Download All Attachments to a Specified Directory
+*** TODO Download Attachment Plus Open Directory in Dired
+*** TODO Consider implementing https://github.com/lordpretzel/mu4e-views
+
+*** TODO Make a hydra for mu4e shortcuts
+#+BEGIN_QUOTE
+Hydra
+People sometimes ask about having multi-character shortcuts for bookmarks; an easy way to achieve this, is by using an emacs package Hydra.
+
+With Hydra installed, we can add multi-character shortcuts, for instance:
+
+(defhydra my-mu4e-bookmarks-work (:color blue)
+ "work bookmarks"
+ ("b" (mu4e-search "banana AND maildir:/work") "banana")
+ ("u" (mu4e-search "flag:unread AND maildir:/work") "unread"))
+
+(defhydra my-mu4e-bookmarks-personal (:color blue)
+ "personal bookmarks"
+ ("c" (mu4e-search "capybara AND maildir:/personal") "capybara")
+ ("u" (mu4e-search "flag:unread AND maildir:/personal") "unread"))
+
+(defhydra my-mu4e-bookmarks (:color blue)
+ "mu4e bookmarks"
+ ("p" (my-mu4e-bookmarks-personal/body) "Personal")
+ ("w" (my-mu4e-bookmarks-work/body) "Work"))
+
+Now, you can bind a convenient key to my-mu4e-bookmarks/body.
+#+END_QUOTE
+[[https://www.djcbsoftware.nl/code/mu/mu4e/Hydra.html][Hydra (Mu4e 1.12.0 user manual)]]
+Captured On: [2024-04-05 Fri 15:02]
+*** TODO Ensure Mu4e is Your Default Emacs Mail Client
+#+BEGIN_QUOTE
+Emacs allows you to select an e-mail program as the default program it uses when you press C-x m (compose-mail), call report-emacs-bug and so on; see (emacs)Mail Methods.
+
+If you want to use mu4e for this, you can do so by adding the following to your configuration:
+
+(setq mail-user-agent 'mu4e-user-agent)
+Similarly, to specify mu4e as your preferred method for reading mail, customize the variable read-mail-command.
+
+(set-variable 'read-mail-command 'mu4e)
+#+END_QUOTE
+[[https://www.djcbsoftware.nl/code/mu/mu4e/Default-email-client.html][Default email client (Mu4e 1.12.0 user manual)]]
+Captured On: [2024-04-05 Fri 15:06]
+*** TODO Information About the Current Mu4e Header in Echo Area
+#+BEGIN_QUOTE
+It is possible to get information about the current header in the echo-area. You can enable this by setting mu4e-eldoc-support to non-nil.
+#+END_QUOTE
+[[https://www.djcbsoftware.nl/code/mu/mu4e/Eldoc.html][Eldoc (Mu4e 1.12.0 user manual)]]
+Captured On: [2024-04-05 Fri 15:05]
+*** TODO Attach Files to Mu4e Messages Using Dired
+#+BEGIN_QUOTE
+It is possible to attach files to mu4e messages using dired (emacs), using the following steps (based on a post on the mu-discuss mailing list by Stephen Eglen).
+
+(add-hook 'dired-mode-hook 'turn-on-gnus-dired-mode)
+Then, mark the file(s) in dired you would like to attach and press C-c RET C-a, and you’ll be asked whether to attach them to an existing message, or create a new one.
+#+END_QUOTE
+[[https://www.djcbsoftware.nl/code/mu/mu4e/Dired.html][Dired (Mu4e 1.12.0 user manual)]]
+Captured On: [2024-04-05 Fri 15:03]
+*** TODO Mail Settings for (Email) Address-at-point
+#+BEGIN_QUOTE
+(use-package goto-addr
+ :bind (
+ :map goto-address-highlight-keymap
+ ("C-c C-o" . goto-address-at-point))
+ :hook (((prog-mode magit-process-mode) . goto-address-mode))
+ :config
+ (progn
+ ;; Recommended by modus-themes (2.7.0 release notes):
+ (setq goto-address-mail-face 'link)
+ (setq goto-address-mail-mouse-face 'highlight)))
+#+END_QUOTE
+[[https://github.com/DamienCassou/emacs.d/blob/master/init.el#L352][emacs.d/init.el at master · DamienCassou/emacs.d]]
+Captured On: [2024-04-05 Fri 14:35]
+** Emacs Markdown Config Backlog [0/1]
+*** TODO Finish Markdown Preview Functionality
+** Emacs Modeline Backlog [0/3]
+*** TODO Consider Mini-modeline for Emacs
+[[https://github.com/kiennq/emacs-mini-modeline][kiennq/emacs-mini-modeline: Display emacs mode line in minibuffer]]
+Captured On: [2023-11-18 Sat 07:44]
+*** TODO Investigate Feebleline's Window-divider-mode
+I have no idea what that is. And I should by now, shouldn't I?
+#+BEGIN_QUOTE
+feebleline
+
+(use-package feebleline
+:bind (("M-o m" . feebleline-mode))
+:config
+(window-divider-mode t))
+#+END_QUOTE
+[[https://github.com/jwiegley/dot-emacs/blob/master/init.org][dot-emacs/init.org at master · jwiegley/dot-emacs]]
+Captured On: [2023-07-31 Mon 16:34]
+*** TODO Investigate Org-upcoming-modeline
+https://github.com/unhammer/org-upcoming-modeline there we go :)
+found on this reddit post
+[[https://www.reddit.com/r/emacs/comments/k1e4eu/show_next_orgappointment_in_modeline/][(4) Show next (org-)appointment in modeline? : emacs]]
+Captured On: [2023-10-10 Tue 09:55]
+** Emacs Org Agenda / Calendar Backlog [0/6]
+*** TODO Add Todo Searching to Emacs With Rg Package
+#+BEGIN_QUOTE
+I'm not sure about todo modes, but using the rg (ripgrep) package, it is easy to add custom commands. For example, to define a command that searches for 'TODO' or 'FIXME' in the current project,
+
+(rg-define-search my-rg-todo
+:query "(TODO|FIXME)"
+:format regexp
+:dir project
+:files current)
+There are a lot of other similar solutions, like builtin rgrep, ag or another ripgrep/ag library.
+#+END_QUOTE
+[[https://stackoverflow.com/questions/76391866/how-to-show-a-list-of-all-my-todos-across-all-the-files-of-my-project][emacs - How to show a list of all my todos across all the files of my project? - Stack Overflow]]
+Captured On: [2024-02-24 Sat 18:13]
+*** TODO Agenda Schedule Should List All DOING and Priority #A Tasks
+*** TODO Consider Implementing Agendas in Org QL
+https://github.com/alphapapa/org-ql
+*** TODO Consider Org Fancy Priorities Package
+[[https://github.com/harrybournis/org-fancy-priorities][harrybournis/org-fancy-priorities: Display Org Mode priorities as custom strings]]
+Captured On: [2023-11-01 Wed 12:05]
+*** TODO Org Crypt and Logbook Work Together for Secure Agenda
+[[https://ag91.github.io/blog/2020/08/28/org-crypt-and-logbook-how-they-can-work-together-for-a-secure-agenda/][Org crypt and LOGBOOK: how they can work together for a secure agenda. - Where parallels cross]]
+Captured On: [2023-11-10 Fri 17:37]
+*** TODO Slack Links in Org Agenda
+[[https://ag91.github.io/blog/2020/09/24/composition-update-add-slack-links-to-org-agenda/][Composition Update: Slack links in your Org Agenda - Where parallels cross]]
+Captured On: [2023-11-10 Fri 17:39]
+*** TODO Fix Org-contacts and Birthdays
+Birthdays aren't showing up in the agenda from org-contacts
+*** TODO Investigate Org Caldav to Integrate Calendar With Agenda
+#+BEGIN_QUOTE
+(use-package org-caldav
+ :bind (("C-. o S" . org-caldav-sync))
+ :config
+ (progn
+ (setq org-caldav-url "https://licorne.ninja/remote.php/dav/calendars/DamienCassou"
+ org-caldav-calendar-id "personal"
+ org-caldav-inbox org-default-calendar-file
+ org-caldav-files '()
+ org-icalendar-timezone "Europe/Berlin"
+ org-caldav-sync-changes-to-org 'all)
+
+ (defun my/org-caldav-archive-year ()
+ "Archive a given year in my calendar."
+ (interactive)
+ (while (re-search-forward "^ *<2021-.*>$" nil t)
+ (org-archive-subtree)))))
+#+END_QUOTE
+[[https://github.com/DamienCassou/emacs.d/blob/master/init.el#L352][emacs.d/init.el at master · DamienCassou/emacs.d]]
+Captured On: [2024-04-05 Fri 15:24]
+** Emacs Org Babel Backlog [0/3]
+*** TODO Add Org Babel Support for PGN
+[[https://gist.github.com/larrasket/4188cac7d0d034eda6ea99160e94dc57][Add org babel support for Portable Game Notation]]
+Captured On: [2024-01-16 Tue 08:38]
+*** TODO Change File Permissions on Your Emacs Tangle Output
+#+BEGIN_QUOTE
+The following worked. I'm not sure why the original did not, though.
+
+#+BEGIN_SRC bash :tangle ~/.local/bin/tsa-ss :tangle-mode (identity #o700)
+#+END_QUOTE
+[[https://www.reddit.com/r/emacs/comments/159zj0v/weekly_tips_tricks_c_thread/][(2) Weekly Tips, Tricks, &c. Thread : emacs]]
+Captured On: [2023-11-18 Sat 09:07]
+*** TODO Ox Pandoc Org Mode Exporter
+[[https://github.com/emacsorphanage/ox-pandoc][emacsorphanage/ox-pandoc: Another org-mode exporter via pandoc.]]
+Captured On: [2023-11-01 Wed 12:25]
+** Emacs Org Capture Backlog [0/2]
+*** TODO Look Into Org-pdftools to See if This Simplifies the PDF Capture Templates
+[[https://github.com/fuxialexander/org-pdftools][fuxialexander/org-pdftools: A custom org link type for pdf-tools]]
+Captured On: [2023-11-01 Wed 12:34]
+*** TODO Rename Org Webclipper Article Files
+- 'article-archive' should be 'saved-articles'
+- 'article-file' should be 'article-inbox' or something else
+
+** Emacs Org Drill Backlog [0/6]
+*** TODO Create Emacs Drill Questions From This Post About Adding to Lists
+#+BEGIN_QUOTE
+There are many different ways. Not sure if there's a particularly "proper" way. There are considerations you should take depending on how you want to add it (destructively, non-destructively) or if you care a lot about efficiency.
+
+original list (1) things you want to add (2 3 4)
+
+There are many different ways of adding. Things can be added destructively, meaning the original set of numbers is modified or non-destructively, just generating a new list. To see more look at list modification.
+
+This is non-destructive. (append '(1) '(2 3 4)) ;=> '(1 2 3 4)
+
+This is destructive and more indirect (more of a replacement than addition), here it replaces the last element of the list 2 with 2 3 4. Which has the net effect of adding to the list.
+
+If your list is in a variable: (setq my-list '(1 2))
+
+(setcdr my-list '(2 3 4)) ;=> '(2 3 4)
+
+my-list ;=> '(1 2 3 4).
+
+You could also just do a loop with add-to-list or cons. Note I'm assuming you don't care about order.
+
+(dolist (thing things) (add-to-list 'list-var thing))
+
+(dolist (thing things) (cons thing list-var))
+
+I usually use the append as it is short to write and more direct. It also is probably among the fastest because it is written in C code whereas add-to-list is in elisp.
+
+Share
+Improve this answer
+Follow
+answered Jan 10, 2018 at 15:56
+
+Piglet
+14644 bronze badges
+append is only efficient if all additional elements are already contained in a list and that list is added. It is inefficient for adding many elements sequentially or in small hunks at the tail since in this case its cost grows quadratically with the number of list entries. Note that I have confirmed that fact by timing. –
+Tobias
+Jan 10, 2018 at 16:54
+Add a comment
+
+3
+
+
+The proper way to add many items to a list is consing in a loop.
+
+If l is the list variable you add an item i by
+
+(setq l (cons i l))
+for which you can use the shorthand
+
+(push i l)
+The computational cost of this operation is independent of the length of the list l.
+
+After collecting the items in this way they are in reverse order. If it is important to retain the order you can call
+
+(setq l (nreverse l))
+as the last action or just return (nreverse l). The cost of nreverse grows just linearly with the length of the list.
+
+The costs of adding all elements with add-to-list grow quadratically with the length of the list (even without append set to t).
+
+If you want to add an item to a list only if it is not already present. You have to search for that item. In that case you could consider using a hashmap (search the elisp info files for make-hash-table) or a sorted list to reduce the computational costs. Note that a single hash access is costly but the read/write access time is essentially independent on the number of elements in the hash.
+
+Share
+Improve this answer
+Follow
+edited Jan 17, 2018 at 13:23
+
+Stefan
+26.2k33 gold badges4848 silver badges8585 bronze badges
+answered Jan 10, 2018 at 15:05
+
+Tobias
+32.7k11 gold badge3434 silver badges7575 bronze badges
+Add a comment
+
+3
+
+
+I figured this question lacks an actual practical example that a person can copy-paste into their config, so here it is:
+
+(defun merge-list-to-list (dst src)
+"Merges content of the 2nd list with the 1st one"
+(set dst
+(append (eval dst) src)))
+It combines the non-destructive append function that merges two lists, and a destructive set.
+
+Now, let's say your config had this code:
+
+(add-to-list 'company-dabbrev-code-modes 'c++-mode)
+(add-to-list 'company-dabbrev-code-modes 'c-mode)
+(add-to-list 'company-dabbrev-code-modes 'php-mode)
+
+(add-to-list 'auto-mode-alist '("\\.mzn\\'" . minizinc-mode))
+(add-to-list 'auto-mode-alist '("\\.glade$\\'" . xml-mode))
+(add-to-list 'auto-mode-alist '("\\PKGBUILD\\'" . sh-mode))
+(add-to-list 'auto-mode-alist '("\\.service\\'" . conf-mode))
+(add-to-list 'auto-mode-alist '("\\.m$" . octave-mode))
+You replace it with this:
+
+(merge-list-to-list 'company-dabbrev-code-modes
+'(c++-mode c-mode php-mode))
+
+(merge-list-to-list 'auto-mode-alist
+'(("\\.mzn\\'" . minizinc-mode)
+("\\.glade$\\'" . xml-mode)
+("\\PKGBUILD\\'" . sh-mode)
+("\\.service\\'" . conf-mode)
+("\\.m$" . octave-mode)))
+Share
+Improve this answer
+Follow
+edited Jun 10 at 2:58
+answered Aug 10, 2021 at 17:23
+
+Hi-Angel
+54466 silver badges1818 bronze badges
+The purported analogy to add-to-list is misleading, as the most notable feature of add-to-list is that it doesn't add an item which already exists in the list. If you want append you should just use append, rather than wrapping that with a name that doesn't behave the way one would expect. –
+phils
+Jun 9 at 9:12
+1
+@phils append doesn't mutate original list though. Regarding the analogy: I honestly didn't even know add-to-list checks for duplicates. I would disagree calling it a "notable feature", because you would only know that from the docs or someone else. It is actually misleading, because the name of the function says nothing at all about removing dups. So in this case it's add-to-list that is misnamed and not the add-list-to-list. With that said, I can rename it if you think it would confuse old-timers. Perhaps, add-list-to-list-allow-dups…? –
+Hi-Angel
+Jun 9 at 12:53
+"you would only know that from the docs" -- I don't think that's much of a problem unless you're in the habit of using unfamiliar elisp functions without even reading their docstrings (which I would consider fairly inexplicable). If I was to write such a function I would probably put append somewhere in the name. –
+phils
+Jun 9 at 13:08
+@phils problem with append tho is this name does not imply the lists are merged. That is, upon executing (setq lhs '(1 2)) (append-list-to-list lhs '(3 4)) I would expect lhs to become (1 2 (3 4)) rather than (1 2 3 4). And yes, I don't necessarily read documentation if the name of the method is self-explanatory, such as print or while or goto-line. This ain't "inexplicable", in huge codebases you can't expect every function have docs, especially so given they have tendency to become outdated. The purpose of the function should be clear from its name and type-definition. –
+Hi-Angel
+Jun 10 at 2:49
+So, I think merge-list-to-list might be a better naming, changed to it for now. –
+Hi-Angel
+Jun 10 at
+#+END_QUOTE
+[[https://emacs.stackexchange.com/questions/38008/adding-many-items-to-a-list/68048#68048][Adding many items to a list - Emacs Stack Exchange]]
+Captured On: [2023-10-22 Sun 00:48]
+*** TODO Find Good Drill Questions in the Elisp Cookbook
+[[https://www.emacswiki.org/emacs/ElispCookbook][EmacsWiki: Elisp Cookbook]]
+Captured On: [2023-10-22 Sun 02:43]
+*** TODO Move Vocabulary List to Org-Drill
+Where I Left Off in the Vocabulary List for Org-Drill
+#+BEGIN_QUOTE
+compunction
+a feeling of deep regret, usually for some misdeed
+#+END_QUOTE
+[[https://www.vocabulary.com/lists/191545][300 Most Difficult "SAT" Words - Vocabulary List | Vocabulary.com]]
+Captured On: [2023-10-27 Fri 03:13]
+*** TODO Use constants instead of hardcoding files/paths in org-drill-config
+*** TODO Emacs Org Drill Flashcard
+[[https://github.com/pdelfino/emacs-flashcards/blob/main/emacs.org][emacs-flashcards/emacs.org at main · pdelfino/emacs-flashcards]]
+Captured On: [2024-04-05 Fri 16:20]
+*** TODO Good blog on Anki and Emacs
+[[https://yiufung.net/post/anki-org/][Power up Anki with Emacs, Org mode, anki-editor and more]]
+Captured On: [2024-04-05 Fri 16:26]
+** Emacs Org Export Backlog [0/1]
+*** TODO Add simple keybinding for org to beamer presentations in org-export-config
+** Emacs Org General Backlog [0/10]
+*** TODO Add Company-org-block to Org Mode Config
+[[https://github.com/xenodium/company-org-block/tree/aee601a2bfcc86d26e762eeb84e5e42573f8c5ca][xenodium/company-org-block at aee601a2bfcc86d26e762eeb84e5e42573f8c5ca]]
+Captured On: [2023-11-01 Wed 12:51]
+*** TODO Copy Formatted Content From Org Mode
+jkitchin/ox-clip: Copy formatted content from org-mode]]
+Captured On: [2023-11-01 Wed 12:27]
+*** TODO Emacs Config Should Work Without Personal Org Files
+*** TODO Interesting Org Mode Navigation Hydra
+#+BEGIN_QUOTE
+Org Mode Navigation
+I use Org Mode constantly, and so here is a hydra I use to navigate such files:
+
+(defhydra hydra-org (:color red :columns 3)
+"Org Mode Movements"
+("n" outline-next-visible-heading "next heading")
+("p" outline-previous-visible-heading "prev heading")
+("N" org-forward-heading-same-level "next heading at same level")
+("P" org-backward-heading-same-level "prev heading at same level")
+("u" outline-up-heading "up heading")
+("g" org-goto "goto" :exit t))
+This demonstrates the :columns feature of Hydra, which is a nice and quick way to neatly format the display of hydras in the minibuffer without resorting to the amazing things you can do with fancy formatting strings.
+#+END_QUOTE
+[[https://ericjmritz.wordpress.com/2015/10/14/some-personal-hydras-for-gnu-emacs/][Some Personal Hydras for GNU Emacs – One More Game-Dev and Programming Blog]]
+Captured On: [2023-11-19 Sun 16:49]
+*** TODO Monospace Fonts in Org Tables
+[[https://github.com/alphapapa/unpackaged.el?tab=readme-ov-file#force-monospace-face-in-tables][alphapapa/unpackaged.el: A collection of useful Emacs Lisp code that isn't substantial enough to be packaged]]
+Captured On: [2024-03-11 Mon 10:07]
+*** TODO Org Mode Links for Emacs Slack
+[[https://ag91.github.io/blog/2020/09/12/org-mode-links-for-emacs-slack/][Org mode links for Emacs Slack - Where parallels cross]]
+Captured On: [2023-11-10 Fri 17:38]
+*** TODO Org Mode Useful Anchors
+[[https://github.com/alphapapa/unpackaged.el?tab=readme-ov-file#export-to-html-with-useful-anchors][alphapapa/unpackaged.el: A collection of useful Emacs Lisp code that isn't substantial enough to be packaged]]
+Captured On: [2024-03-11 Mon 10:06]
+*** TODO Org-Tidy Hides Property Drawers
+[[https://github.com/jxq0/org-tidy][jxq0/org-tidy: 🧹 An Emacs minor mode to automatically tidy org-mode property drawers]]
+Captured On: [2023-11-01 Wed 12:28]
+*** TODO Subtasks Inherit Deadline From Parent Task in Emacs Org-mode
+
+Org-mode has the capability to inherit tags like deadlines, but by default org-entry-get does not do so. Here's advice to ensure that DEADLINE is always inherited.
+
+#+BEGIN_QUOTE
+(defun org-entry-properties-inherit-deadline (orig-fun &optional pom which)
+"Call ORIG-FUN with POM, but if WHICH is `DEADLINE' do it recursively."
+
+(if (string= which "DEADLINE")
+(org-with-point-at pom
+(let (value)
+(while (not (or (setq value (funcall orig-fun (point) which))
+(not (org-up-heading-safe)))))
+value)
+(funcall orig-fun pom which))))
+(advice-add 'org-entry-properties :around #'org-entry-properties-inherit-deadline)
+#+END_QUOTE
+
+Also see:
+https://github.com/vedang/emacs-up/commit/1cb6c774a991d50853134d8085ca61dd12585993
+
+
+[[https://stackoverflow.com/questions/4872088/is-there-any-way-for-subtasks-to-inherit-deadlines-in-org-mode][emacs - Is there any way for subtasks to inherit deadlines in org-mode? - Stack Overflow]]
+Captured On: [2023-11-01 Wed 11:38]
+*** TODO Consider Getting an Emacs-buddy Per This Site
+[[https://github.com/ag91/emacs-buddy][GitHub - ag91/emacs-buddy: Emacs Buddy initiative to help new Emacs users with their struggles]]
+Captured On: [2023-11-10 Fri 17:15]
+** Emacs Org Refile Backlog [0/2]
+*** TODO Consider Using Hydras for Refile Targets
+[[https://mollermara.com/blog/Fast-refiling-in-org-mode-with-hydras/][Fast refiling in org-mode with hydras | Josh Moller-Mara]]
+Captured On: [2023-10-23 Mon 14:27]
+*** TODO Look into this setup for Emacs and Org-Protocol
+#+BEGIN_QUOTE
+his is what I did:
+
+**** Create handler for org-protocol urls
+
+We want a small emacs window centred on the screen.
+
+#+BEGIN_SRC sh :tangle ~/scripts/emacs-capture :shebang "#!/bin/sh"
+emacsclient -c -F "((name . \"emacs-capture\") (height . 10) (width . 80) (left . 632) (top . 452) (user-position . t) (menu-bar-lines . 0))" "$@"
+#+END_SRC
+
+The =left= and =top= cells do the centering for a 1920x1080
+display. For other sizes, =xwininfo= is yr friend: left =
+(x-screen - x-window)/2 and so on.
+
+**** Register handler for org-protocol
+
+#+BEGIN_SRC sh :tangle ~/.local/share/applications/emacs-capture.desktop
+[Desktop Entry]
+Name=Org Capture
+Exec=/home/fran/scripts/emacs-capture %u
+Comment=Capture the web into org
+Icon=/usr/share/icons/hicolor/scalable/apps/emacs24.svg
+Type=Application
+Terminal=false
+MimeType=x-scheme-handler/org-protocol;
+#+END_SRC
+
+After installing this, you need to evaluate (with =C-c C-c=)
+the following to register the mime-type with the OS:
+
+#+NAME: update-block
+#+BEGIN_SRC sh
+update-desktop-database ~/.local/share/applications
+#+END_SRC
+#+END_QUOTE
+[[https://www.reddit.com/r/emacs/comments/fvlcqg/anyone_using_orgprotocol_with_only_a_window/][(3) Anyone using org-protocol with only a window manager but no desktop environment? : emacs]]
+Captured On: [2024-04-02 Tue 16:54]
+** Emacs Org Roam Backlog [0/5]
+*** TODO Compare Orgrr versus Org-Roam
+[[https://github.com/rtrppl/orgrr][GitHub - rtrppl/orgrr: Orgrr is a minimalist but complete note-taking system for Emacs. Its intended purpose is the creation and management of a Zettelkasten-like system.]]
+Captured On: [2023-11-18 Sat 11:01]
+*** TODO Describe Org-roam Types in Org-roam-config.el Commentary
+*** TODO Finish Org Roam Hydra
+**** TODO Example Org Roam Hydra 1
+
+;; (org-roam-hydra (:color blue :hint nil)
+;; "== Org Roam Menu == [ Note: invoke Org-Roam's completion-at-point with 'C-M-i' ]
+;; "
+;; ("f" org-roam-node-find "Find/Add Node (C-c n f)" :column "Node")
+;; ("p" cj/org-roam-find-project "Find/Add Project (C-c n p)" :column "Node")
+;; ("r" cj/org-roam-find-recipe "Find/Add Recipe (C-c n r)" :column "Node")
+;; ("t" cj/org-roam-find-topic "Find/Add Topic (C-c n t)" :column "Node")
+;; ("i" org-roam-node-insert "Insert Link to Node (C-c n i)" :column "Node")
+;; ("I" cj/org-roam-node-insert-immediately "Insert Link to Node Immediately (C-c n I)" :column "Node")
+;; ("n" org-roam-dailies-capture-today "Add Entry for Today (C-c n d n)" :column "Journal")
+;; ("d" org-roam-dailies-goto-today "Goto Today's Entry (C-c n d d)" :column "Journal")
+;; ("T" org-roam-dailies-capture-tomorrow "Add Entry for Tomorrow (C-c n d T)" :column "Journal")
+;; ("Y" org-roam-dailies-capture-yesterday "Add Entry for Yesterday (C-c n d Y)" :column "Journal")
+;; ("v" org-roam-dailies-capture-date "Add Entry for Specific Date (C-c n d v)" :column "Journal")
+;; ("c" org-roam-dailies-goto-date "Goto Entry for Specific Date (C-c n d c)" :column "Journal")
+;; (">" org-roam-dailies-goto-next-note "Goto Next Entry (C-c n d f)" :column "Journal")
+;; ("<" org-roam-dailies-goto-previous-note "Goto Previous Entry (C-c n d b)" :column "Journal")
+;; )
+;; :hydra
+;; (org-roam-hydra (:color blue :hint nil)
+;; "== Org Roam Menu == [ Note: invoke Org-Roam's completion-at-point with 'C-M-i' ]
+;; "
+;; ("f" org-roam-node-find "Find/Add Node (C-c n f)" :column "Node")
+;; ("p" cj/org-roam-find-project "Find/Add Project (C-c n p)" :column "Node")
+;; ("r" cj/org-roam-find-recipe "Find/Add Recipe (C-c n r)" :column "Node")
+;; ("t" cj/org-roam-find-topic "Find/Add Topic (C-c n t)" :column "Node")
+;; ("i" org-roam-node-insert "Insert Link to Node (C-c n i)" :column "Node")
+;; ("I" cj/org-roam-node-insert-immediately "Insert Link to Node Immediately (C-c n I)" :column "Node")
+;; ("n" org-roam-dailies-capture-today "Add Entry for Today (C-c n d n)" :column "Journal")
+;; ("d" org-roam-dailies-goto-today "Goto Today's Entry (C-c n d d)" :column "Journal")
+;; ("T" org-roam-dailies-capture-tomorrow "Add Entry for Tomorrow (C-c n d T)" :column "Journal")
+;; ("Y" org-roam-dailies-capture-yesterday "Add Entry for Yesterday (C-c n d Y)" :column "Journal")
+;; ("v" org-roam-dailies-capture-date "Add Entry for Specific Date (C-c n d v)" :column "Journal")
+;; ("c" org-roam-dailies-goto-date "Goto Entry for Specific Date (C-c n d c)" :column "Journal")
+;; (">" org-roam-dailies-goto-next-note "Goto Next Entry (C-c n d f)" :column "Journal")
+;; ("<" org-roam-dailies-goto-previous-note "Goto Previous Entry (C-c n d b)" :column "Journal")
+;; )
+
+**** TODO Example Org Roam Hydra 2
+
+- What's the key binding for this?
+
+#+BEGIN_QUOTE
+Hydra / Roam
+Group org-roam commands.
+
+(pretty-hydra-define hydra-notes
+(:hint nil :color teal :quit-key "q" :title (with-octicon "pencil" "Notes" 1 -0.05))
+("Notes"
+(("c" org-roam-dailies-capture-today "capture")
+("C" org-roam-dailies-capture-tomorrow "capture tomorrow")
+("g" org-roam-graph "graph")
+("f" org-roam-node-find "find")
+("i" org-roam-node-insert "insert"))
+"Go To"
+((">" org-roam-dailies-goto-next-note "next note")
+("<" org-roam-dailies-goto-previous-note "previous note")
+("d" org-roam-dailies-goto-date "date")
+("t" org-roam-dailies-goto-today "today")
+("T" org-roam-dailies-goto-tomorrow "tomorrow")
+("y" org-roam-dailies-goto-yesterday "yesterday"))))
+#+END_QUOTE
+[[https://github.com/rememberYou/.emacs.d/blob/master/config.org][.emacs.d/config.org at master · rememberYou/.emacs.d]]
+Captured On: [2023-11-19 Sun 17:26]
+*** TODO Good Read on Org-Roam
+[[https://blog.dornea.nu/2022/09/03/migrate-tiddlywiki-to-org-roam-part-1-export-tiddlers/][Migrate Tiddlywiki to org-roam - Part 1: Export Tiddlers - blog.dornea.nu]]
+Captured On: [2023-10-21 Sat 08:41]
+*** TODO Look into Delve for Org-Roam
+[[https://github.com/publicimageltd/delve][publicimageltd/delve: Delve into your org-roam zettelkasten]]
+Captured On: [2024-04-05 Fri 13:57]
+** Emacs PDF Backlog [0/2]
+*** TODO Double Check PDF-tools Settings Across All Emacs Functionality
+[[https://emacs.stackexchange.com/questions/19686/how-to-use-pdf-tools-pdf-view-mode-in-emacs][gnus - How to use pdf-tools (pdf-view-mode) in emacs? - Emacs Stack Exchange]]
+Captured On: [2023-10-20 Fri 10:44]
+*** TODO Consider Using Org-Noter for PDF Annotations
+[[https://github.com/weirdNox/org-noter][weirdNox/org-noter: Emacs document annotator, using Org-mode]]
+Captured On: [2023-10-20 Fri 12:07]
+** Emacs Prog Comments Backlog [0/1]
+*** TODO Emacs Comments Related
+**** TODO Add Elisp Quote to Comments
+#+BEGIN_QUOTE
+;; ---------------------------------- ;;
+;; External function decls
+;; ---------------------------------- ;;
+
+#+END_QUOTE
+[[][]]
+Captured On: [2023-10-30 Mon 10:24]
+** Emacs Prog General Backlog [0/28]
+*** VERIFY Reuse Constants for Projectile Searching in prog-general.el
+#+BEGIN_QUOTE
+(setq projectile-project-search-path '("~/code" "~/projects" "~/.emacs.d" "~/.dotfiles"))
+#+END_QUOTE
+Captured On: [2023-08-28 Mon 03:07]
+*** TODO Add Consult-todos, Magit-todos, or a Way to Search for Todo Comments in Code.
+*** TODO Add Copilot.el
+https://github.com/copilot-emacs/copilot.el
+*** TODO An Emacs Refactoring Package
+[[https://github.com/Wilfred/emacs-refactor#user-content-general][Wilfred/emacs-refactor: language-specific refactoring in Emacs]]
+Captured On: [2023-08-12 Sat 11:41]
+*** TODO Check on Shellcheck and Emacs
+#+BEGIN_QUOTE
+
+Julia Evans had a great talk called Making Hard Things Easy. One of the takeaways for me was that I should be using tools for
+parts of a system I find hard to remember. In particular, when writing bash scripts I should be using shellcheck.
+
+It turns out Emacs 29 has support for shellcheck, and older versions of Emacs can use the flymake-shellcheck page.
+
+To set it up in Emacs 29:
+
+(use-package flymake
+:bind (("H-e" . flymake-show-project-diagnostics))
+
+(use-package sh-script
+:hook (sh-mode . flymake-mode))
+
+I use consult for navigating my errors, and I want to make errors more noticable in the mode line, so my flymake configuration
+is:
+
+(use-package flymake
+:bind (("H-e" . my/consult-flymake-project))
+:preface
+(defun my/consult-flymake-project ()
+(interactive)
+(consult-flymake t))
+:custom
+(flymake-suppress-zero-counters t)
+:config
+(defface my/flymake-modeline-error-echo
+'((t :inherit 'flymake-error-echo :background "red"))
+"Mode line flymake errors")
+(put 'flymake-error 'mode-line-face 'my/flymake-modeline-error-echo)
+(defface my/flymake-modeline-warning-echo
+'((t :inherit 'flymake-warning-echo :background "orange"))
+"Mode line flymake warnings")
+(put 'flymake-warning 'mode-line-face 'my/flymake-modeline-warning-echo))
+
+It's too early to know what other tweaks I might want, but so far it's alerted me to several errors in my shell scripts.
+
+Update: [2023-10-07] Comments on HN pointed to bash-language-server which works with emacs lsp or eglot.
+
+#+END_QUOTE
+Source: [[https://amitp.blogspot.com/2023/10/emacs-and-shellcheck.html][*eww*]]
+Captured On: [2023-10-09 Mon 13:42]
+*** TODO Check Out Project.el Against Projectile
+[[https://www.reddit.com/r/emacs/comments/176vrhs/projectel_vs_projectile_what_things_can_one_do/][(3) Project.el vs. Projectile: What things can one do that the other cannot? : emacs]]
+Captured On: [2023-10-13 Fri 15:53]
+*** TODO Consider Adding Back Emacs-format-all-the-code
+https://github.com/lassik/emacs-format-all-the-code
+*** TODO Decide Whether You Need Global Ligature Mode or if It Should Be a Hook
+*** TODO Great Projectile Hydra to Consider
+[[https://github.com/abo-abo/hydra/wiki/Projectile][Projectile · abo-abo/hydra Wiki]]
+Captured On: [2023-11-19 Sun 17:15]
+*** TODO Highlight Numeric Literals
+#+BEGIN_QUOTE
+(use-package highlight-numbers
+:hook (prog-mode . highlight-numbers-mode))
+#+END_QUOTE
+[[https://github.com/jwiegley/dot-emacs/blob/master/init.org][dot-emacs/init.org at master · jwiegley/dot-emacs]]
+Captured On: [2023-07-31 Mon 16:47]
+*** TODO Investigate Goto-last-change
+
+goto-last-change.el was written in response to the following:
+
+From: Dan Jacobson <jidanni@jidanni.org>
+Newsgroups: gnu.emacs.bug
+Subject: function to go to spot of last change
+Date: Sun, 15 Jun 2003 00:15:08 +0000 (UTC)
+Sender: news <news@main.gmane.org>
+Message-ID: <mailman.7910.1055637181.21513.bug-gnu-emacs@gnu.org>
+NNTP-Posting-Host: monty-python.gnu.org
+
+
+Why of course, a function to get the user to the spot of last changes
+in the current buffer(s?), that's what emacs must lack.
+
+How many times have you found yourself mosying [<-not in spell
+checker!?] thru a file when you wonder, where the heck was I just
+editing? Well, the best you can do is hit undo, ^F, and undo again,
+to get back. Hence the "burning need" for the additional function,
+which you might name the-jacobson-memorial-function, due to its brilliance.
+--
+http://jidanni.org/ Taiwan(04)25854780
+#+BEGIN_QUOTE
+goto-last-change
+
+(use-package goto-last-change
+:bind ("C-x C-/" . goto-last-change))
+#+END_QUOTE
+[[https://github.com/jwiegley/dot-emacs/blob/master/init.org][dot-emacs/init.org at master · jwiegley/dot-emacs]]
+Captured On: [2023-07-31 Mon 16:40]
+*** TODO Investigate Hideshow
+#+BEGIN_QUOTE
+hideshow
+
+(use-package hideshow
+:diminish hs-minor-mode
+:hook (prog-mode . hs-minor-mode)
+:bind (:map prog-mode-map
+("C-c h" . hs-toggle-hiding)))
+#+END_QUOTE
+[[https://github.com/jwiegley/dot-emacs/blob/master/init.org][dot-emacs/init.org at master · jwiegley/dot-emacs]]
+Captured On: [2023-07-31 Mon 16:46]
+*** TODO Investigate Realgud - External Debugger Interface
+#+BEGIN_QUOTE
+An extensible, modular GNU Emacs front-end for interacting with external debuggers,
+#+END_QUOTE
+[[https://github.com/realgud/realgud/tree/2c77776a4797805d8633636fd68148dfb32fab65][realgud/realgud at 2c77776a4797805d8633636fd68148dfb32fab65]]
+Captured On: [2023-07-31 Mon 16:43]
+*** TODO Investigate Tmux + Emacs + Projectile-test
+https://www.reddit.com/r/emacs/comments/xyo2fo/orgmode_vterm_tmux/
+*** TODO Investigate Vagrant Emacs Integration
+#+BEGIN_QUOTE
+vagrant
+
+(use-package vagrant
+:commands (vagrant-up
+vagrant-ssh
+vagrant-halt
+vagrant-status)
+:functions (vagrant-tramp-enable)
+:config
+(vagrant-tramp-enable))
+
+vagrant-tramp
+
+(use-package vagrant-tramp
+:after tramp)
+#+END_QUOTE
+[[https://github.com/jwiegley/dot-emacs/blob/master/init.org][dot-emacs/init.org at master · jwiegley/dot-emacs]]
+Captured On: [2023-07-31 Mon 17:28]
+*** TODO Investigate Vimish Fold
+#+BEGIN_QUOTE
+vimish-fold
+
+(use-package vimish-fold
+:bind (("C-c V f" . vimish-fold)
+("C-c V d" . vimish-fold-delete)
+("C-c V D" . vimish-fold-delete-all)))
+#+END_QUOTE
+[[https://github.com/jwiegley/dot-emacs/blob/master/init.org][dot-emacs/init.org at master · jwiegley/dot-emacs]]
+Captured On: [2023-07-31 Mon 17:31]
+*** TODO Learn How Project.el Works in Emacs
+*** TODO Look Into Reformatter Emacs Package
+[[https://elpa.nongnu.org/nongnu/reformatter.html][NonGNU ELPA - reformatter]]
+Captured On: [2023-10-13 Fri 14:07]
+*** TODO Look into Regex Tool
+[[https://melpa.org/#/regex-tool][regex-tool - MELPA]]
+Captured On: [2023-07-31 Mon 17:19]
+*** TODO Look into REPL Driven Development Emacs Package
+[[https://github.com/alhassy/repl-driven-development/tree/05bd1cee8f298173010ed17a98ba2b94cb08d830][GitHub - alhassy/repl-driven-development at 05bd1cee8f298173010ed17a98ba2b94cb08d830]]
+Captured On: [2023-12-06 Wed 13:34]
+*** TODO Managing Todo Tasks in Project
+[[https://www.reddit.com/r/emacs/comments/fs7tk3/how_to_manage_todo_tasks_in_my_project/][(2) How to manage TODO tasks in my project? : emacs]]
+Captured On: [2024-02-26 Mon 11:01]
+*** TODO Read Emacs Package Dev Handbook
+[[https://github.com/alphapapa/emacs-package-dev-handbook][alphapapa/emacs-package-dev-handbook: An Emacs package development handbook. Built with Emacs, by Emacs package developers, for Emacs package developers.]]
+Captured On: [2023-10-29 Sun 13:03]
+*** TODO Real-time Collaborative Editing Environment for Emacs
+[[https://github.com/zaeph/crdt.el][zaeph/crdt.el]]
+Captured On: [2023-07-31 Mon 15:59]
+*** TODO Review Refactorings in Emacs
+#+BEGIN_QUOTE
+Look right at the second example here:
+https://joaotavora.github.io/yasnippet/snippet-development.html#orgcde188c
+
+for ($1;$2;$3) { `yas-selected-text`$0 }
+
+Note that you have some text selected, and the snippet expands around the text. This is the simplest way to create refactorings, say you want to put some text into a function:
+
+def ${1:fun_name}(${2:arg}) =
+$0`yas-selected-text`
+
+Note also that you can use yasnippet to trigger as a command and it will interpret the body as lisp code, too.
+
+Then bind the whole thing to a custom key binding, and you have some nice refactoring that will create a function for you from the selected text. I usually just kill it and yank it where needed, but since you can embed elisp you can probably also automate that to get it in scope using up/down-list. I just never take the time since expand selection and kill are like 3 keystrokes for me.
+
+Yasnippets can get really complex, especially with mirroring and transformations and things that move text around.
+#+END_QUOTE
+[[https://www.reddit.com/r/emacs/comments/o1o7w6/refactoring_support/][(2) Refactoring support : emacs]]
+Captured On: [2023-08-12 Sat 11:33]
+*** TODO Rework Prog-shell to Make Shell Script Ide
+https://www.reddit.com/r/emacs/comments/onpv90/emacs_as_shell_script_ide/
+*** TODO Save Just the Project Buffers in Emacs
+#+BEGIN_QUOTE
+(defun project-save-buffers (&optional arg)
+"Save modified file-visiting buffers of current project, if any.
+Based on `save-some-buffers', refer to its documentation about interactive
+behavior and the optional argument ARG."
+(interactive "P")
+(save-excursion
+(when-let* ((project (project-current))
+(buffers (project-buffers project)))
+(save-some-buffers arg
+(lambda ()
+(memq (current-buffer) buffers))))))
+#+END_QUOTE
+[[https://www.reddit.com/r/emacs/comments/159zj0v/weekly_tips_tricks_c_thread/][(2) Weekly Tips, Tricks, &c. Thread : emacs]]
+Captured On: [2023-11-18 Sat 09:09]
+*** TODO Check the languages you code in have DAP interfaces
+*** TODO Investigate Dap Move for Prog General
+**** Github Repo
+[[https://github.com/emacs-lsp/dap-mode?tab=readme-ov-file][emacs-lsp/dap-mode: Emacs Debug Adapter Protocol]]
+Captured On: [2024-04-05 Fri 14:02]
+** Emacs Prog Go Backlog [0/5]
+*** VERIFY Emacs Not Displaying Ligatures in Go-mode
+*** TODO Add Ob-go to Org Configuration
+[[https://github.com/pope/ob-go/tree/2067ed55f4c1d33a43cb3f6948609d240a8915f5][pope/ob-go at 2067ed55f4c1d33a43cb3f6948609d240a8915f5]]
+Captured On: [2023-11-01 Wed 12:46]
+*** TODO Go Environment Variables in Emacs
+#+BEGIN_QUOTE
+I was trying to figure out how to get emacs to update my go version based on what I've set via goenv. Using the exec-path-from-shell package I was able to come up with this, hoping someone else will find this useful:
+
+(defun go-update-env ()
+"sets go related environment variables to match the project's version specified by goenv"
+(interactive)
+(if (directory-files (projectile-project-root) :MATCH "\.go-version")
+(progn
+(dolist (var '("GOMODCACHE" "GOPATH" "GOROOT" "GOTOOLDIR" "GOVERSION"))
+(add-to-list 'exec-path-from-shell-variables var))
+(exec-path-from-shell-initialize))
+(message "warning: no .go-version file found in project root"))
+(go-mode)
+)
+#+END_QUOTE
+[[https://www.reddit.com/r/emacs/comments/14377k9/weekly_tips_tricks_c_thread/][(2) Weekly Tips, Tricks, &c. Thread : emacs]]
+Captured On: [2023-11-18 Sat 08:42]
+*** TODO Consider Go Resources Here
+https://github.com/emacs-tw/awesome-emacs#go
+perhaps especially
+https://github.com/dominikh/go-mode.el
+https://github.com/nlamirault/gotest.el
+*** TODO Prog-go uses project.el and I shouldn't need it
+** Emacs Prog Lisps Backlog [0/4]
+*** TODO Lint and Test Emacs Lisp?
+[[https://github.com/alphapapa/makem.sh][alphapapa/makem.sh: Makefile-like script for linting and testing Emacs Lisp packages]]
+Captured On: [2023-10-02 Mon 00:34]
+*** TODO Look Into Rainbow Blocks for Highlighting Scope and Depth, Not Syntax
+[[https://github.com/istib/rainbow-blocks][istib/rainbow-blocks: block syntax highlighting in emacs]]
+Captured On: [2024-03-28 Thu 15:04]
+*** TODO Slime Emacs Config
+#+BEGIN_QUOTE
+slime
+
+(use-package slime
+:commands slime
+:custom
+(slime-kill-without-query-p t)
+(slime-repl-history-file (user-data "slime-history.eld"))
+(slime-startup-animation nil)
+:init
+(setq inferior-lisp-program "sbcl"
+slime-contribs '(slime-fancy)))
+#+END_QUOTE
+[[https://github.com/jwiegley/dot-emacs/blob/master/init.org][dot-emacs/init.org at master · jwiegley/dot-emacs]]
+Captured On: [2023-08-01 Tue 07:48]
+*** TODO Review Interesting Elisp Settings
+#+BEGIN_QUOTE
+(use-package elisp-mode
+ :hook ((emacs-lisp-mode . my/elisp-mode-reduce-mode-name)
+ (emacs-lisp-mode . my/eldoc-shows-more-information))
+ :config
+ (progn
+ (defun my/elisp-mode-reduce-mode-name ()
+ (setq-local mode-name "Elisp"))
+
+ (defun my/eldoc-shows-more-information ()
+ (remove-hook 'eldoc-documentation-functions #'elisp-eldoc-var-docstring t)
+ (add-hook 'eldoc-documentation-functions #'elisp-eldoc-var-docstring-with-value nil t))))
+#+END_QUOTE
+[[https://github.com/DamienCassou/emacs.d/blob/master/init.el#L352][emacs.d/init.el at master · DamienCassou/emacs.d]]
+Captured On: [2024-04-05 Fri 14:31]
+** Emacs Prog LSP Backlog [0/1]
+*** TODO [#C] Article on Making LSP and Eglot Faster in Emacs
+[[https://www.reddit.com/r/emacs/comments/16vixg6/how_to_make_lsp_and_eglot_way_faster_like_neovim/][how to make lsp and eglot way faster like neovim? : emacs]]
+Captured On: [2023-10-02 Mon 00:52]
+** Emacs Prog Python Backlog [0/2]
+*** TODO Emacs ABL Mode for Python Programming
+[[https://github.com/afroisalreadyinu/abl-mode][afroisalreadyinu/abl-mode: Emacs minor mode to simplify test-driven development using virtual environments]]
+Captured On: [2023-11-24 Fri 12:00]
+*** TODO Python Multi-Line Shells for REPL based Python Programming
+[[https://github.com/jdtsmith/python-mls][jdtsmith/python-mls: Multi-line Shell Commands for Python REPLs in Emacs]]
+Captured On: [2023-10-27 Fri 11:14]
+** Emacs Prog Testing Backlog [0/4]
+*** TODO Look into Cask and assess for ERT testing
+#+BEGIN_QUOTE
+I am a Cask (http://github.com/cask/cask/) junkie which provides really nice command line invocation of tests, supports multiple versions of Emacs, and runs in a headless environment. I normally run it inside M-x compile.
+
+Testing, I use ert.el. The framework is nice, but the reporting can be poor, and keeping tests independent is hard work (that's Emacs' fault rather than ert, I feel). So if I may be excused the plug, I've written assess (https://github.com/phillord/assess) which adds better reporting, macros for keeping Emacs tests free of side-effects, and adds some nice predicates (for roundtripping indentation, testing font-lock and so on). Probably, assess will go into core for Emacs-26 as ert-assess.
+
+ecukes and buttercup, I cannot really vouch for one way or the other. The whole BDD doesn't entirely make sense to me.
+#+END_QUOTE
+
+[[https://help-gnu-emacs.gnu.narkive.com/DIgoBtwP/tdd-and-bdd-for-emacs-lisp][TDD and BDD for emacs-lisp]]
+Captured On: [2023-10-30 Mon 16:58]
+*** TODO Discussion on running Emacs tests
+[[https://github.com/jorgenschaefer/emacs-buttercup/issues/174][Running tests with an interactive terminal (noninteractive: nil) · Issue #174 · jorgenschaefer/emacs-buttercup]]
+Captured On: [2023-10-29 Sun 14:41]
+*** TODO Restclient API Testing
+**** TODO Restclient.el
+[[https://github.com/pashky/restclient.el][pashky/restclient.el: HTTP REST client tool for emacs]]
+Captured On: [2023-11-01 Wed 15:28]
+**** TODO Ob-Restclient Integrated API Testing Via Org-Babel
+[[https://github.com/alf/ob-restclient.el][alf/ob-restclient.el: An org-mode extension to restclient.el]]
+Captured On: [2023-11-01 Wed 15:28]
+*** TODO TDD Package
+emacs-tdd/tdd.el at master · jorgenschaefer/emacs-tdd]]
+Captured On: [2023-10-30 Mon 17:09]
+** Emacs Prog Webdev Backlog [0/0]
+** Emacs Selection Framework Backlog [0/1]
+*** TODO Create Another Selection Framework Config With Updated Selection Frameworks
+Instead of company with ivy/swiper/counsel, try corfu with selectrum, marginalia, orderless, consult, embark
+
+You can use orderless for filtering and prescient for sorting. They aren't mutually exclusive.
+** Emacs Snippet Backlog [0/4]
+*** TODO Consider Ivy-Yasnippet Integration
+https://github.com/mkcms/ivy-yasnippet
+*** TODO Integrate YASnippet + Yankpad with Org Capture
+https://ag91.github.io/blog/2020/07/28/how-to-integrate-yasnippet-and-yankpad-with-org-capture
+Captured On: [2023-11-10 Fri 17:35]
+*** TODO Yasnippets With New -ts- Major Modes in Emacs
+#+BEGIN_QUOTE
+Advising yasnippet so that existing snippets can work with the new "treesit" -ts- major modes:
+
+
+;;;###autoload
+(defun my-treesit-language-or-major-mode-to-legacy-modes (lang-or-mode)
+(-let* ((lang
+(replace-regexp-in-string
+"\\(-ts\\)?-mode$" "" (format "%s" lang-or-mode))))
+(pcase lang
+
+("bash" '(sh-mode))
+("json" '(json-mode js-json-mode))
+("rust" '(rust-mode rustic-mode))
+
+(_ (list (intern (format "%s-mode" lang)))))))
+
+
+;;;###autoload
+(defun my-yas--modes-to-activate--treesit-modes-a
+(func &optional mode &rest args)
+(cond
+(mode
+(apply func mode args))
+(t
+(-let* ((non-ts-modes
+(my-treesit-language-or-major-mode-to-legacy-modes major-mode)))
+(-->
+`(,@(apply func mode args)
+,@(--mapcat (apply func it args) non-ts-modes))
+(delete-dups it))))))
+
+
+(advice-add #'yas--modes-to-activate :around
+#'my-yas--modes-to-activate--treesit-modes-a)
+
+
+2
+
+
+Reply
+Share
+
+
+
+level 2
+tryptych
+3 mo. ago
+Alternatively, you can add a .yas-parents file to a snippets directory, containing the name of the mode(s) it should "inherit". Eg, if your python-ts-mode snippets directory has a .yas-parents file containing "python-mode", then yasnippets for python-ts-mode will automatically include everything defined for python-mode.
+
+
+3
+
+
+Reply
+Share
+
+
+
+level 3
+takutekato
+3 mo. ago
+Thank you, I didn't know about that.
+
+It appears that https://github.com/AndreaCrotti/yasnippet-snippets has already done it. I will only keep this until https://github.com/doomemacs/snippets is updated, then.
+#+END_QUOTE
+[[https://www.reddit.com/r/emacs/comments/15g2u1t/weekly_tips_tricks_c_thread/][(2) Weekly Tips, Tricks, &c. Thread : emacs]]
+Captured On: [2023-11-18 Sat 09:12]
+*** TODO eshell for loop
+#+BEGIN_QUOTE
+#name : Eshell for loop
+#key : for
+# --
+for f in ${1:*} { ${2:echo} "$f"; $3} $0
+#+END_QUOTE
+[[https://github.com/karthink/yasnippets/blob/master/eshell-mode/for][yasnippets/eshell-mode/for at master · karthink/yasnippets]]
+Captured On: [2024-04-04 Thu 22:58]
+** Emacs Spellcheck Backlog [0/2]
+*** VERIFY Fix Emacs Spellcheck Functionality
+Make it work like Malabarba's post again -- even if it's ugly!
+https://www.reddit.com/r/emacs/comments/8rxm7h/tip_how_to_better_manage_your_spelling_mistakes/
+*** TODO Review Flyspell Config
+**** TODO Review Flyspell Key Bindings
+It should be obvious which key to hit when the cursor is over a mistake to have flyspell provide a list of corrections using completing-read.
+**** TODO Review Flyspell Execution
+There are situations where invoking cj/flyspell-then-abbrev doesn't work.
+Identify those situations and fix.
+** Emacs System Defaults Backlog [0/2]
+*** TODO replacement current yes-or-no replacement in Emacs Config?
+#+BEGIN_QUOTE
+(progn ; `map-ynp'
+ ;; Make all "yes or no" prompts show "y or n" instead
+ (setq read-answer-short t)
+ (setq use-short-answers t))
+#+END_QUOTE
+[[https://github.com/DamienCassou/emacs.d/blob/master/init.el][emacs.d/init.el at master · DamienCassou/emacs.d]]
+Captured On: [2024-04-05 Fri 14:17]
+*** TODO Don't allow the user to switch out of answering y/n questions in minibuffer
+#+BEGIN_QUOTE
+(progn ; `subr'
+ ;; recommended by
+ ;; (info "(embark) How does Embark call the actions?")
+ (setq y-or-n-p-use-read-key t))
+#+END_QUOTE
+[[https://github.com/DamienCassou/emacs.d/blob/master/init.el][emacs.d/init.el at master · DamienCassou/emacs.d]]
+Captured On: [2024-04-05 Fri 14:21]
+** Emacs System Utils Backlog [0/15]
+*** TODO Add Mode-minder to Config Work
+Show All Major and Minor Modes Available in Emacs
+[[https://github.com/jdtsmith/mode-minder][jdtsmith/mode-minder: Show all modes available in Emacs]]
+Captured On: [2023-10-27 Fri 11:10]
+*** TODO Another Hydra for Timers/Alarms
+#+BEGIN_QUOTE
+Hydra / Clock
+Group clock commands.
+
+(pretty-hydra-define hydra-clock
+(:hint nil :color teal :quit-key "q" :title (with-faicon "clock-o" "Clock" 1 -0.05))
+("Action"
+(("c" org-clock-cancel "cancel")
+("d" org-clock-display "display")
+("e" org-clock-modify-effort-estimate "effort")
+("i" org-clock-in "in")
+("j" org-clock-goto "jump")
+("o" org-clock-out "out")
+("p" org-pomodoro "pomodoro")
+("r" org-clock-report "report"))))
+#+END_QUOTE
+[[https://github.com/rememberYou/.emacs.d/blob/master/config.org][.emacs.d/config.org at master · rememberYou/.emacs.d]]
+Captured On: [2023-11-19 Sun 17:23]
+*** TODO Change Narrow to Fancy Narrow
+#+BEGIN_QUOTE
+fancy-narrow
+
+(use-package fancy-narrow
+:bind (("C-c N N" . fancy-narrow-to-region)
+("C-c N W" . fancy-widen))
+:commands (fancy-narrow-to-region fancy-widen))
+#+END_QUOTE
+[[https://github.com/jwiegley/dot-emacs/blob/master/init.org][dot-emacs/init.org at master · jwiegley/dot-emacs]]
+Captured On: [2023-07-31 Mon 16:33]
+*** TODO Check into Engine Mode for Searching Sites
+#+BEGIN_QUOTE
+(use-package engine-mode
+:config
+(defengine my-blog "https://www.google.ca/search?q=site:sachachua.com+%s" :keybinding "b")
+(defengine mail "https://mail.google.com/mail/u/0/#search/%s" :keybinding "m")
+(defengine google "https://google.com/search?q=%s" :keybinding "g")
+(defengine emacswiki "https://google.com/search?q=site:emacswiki.org+%s" :keybinding "e")
+(engine-mode)
+:hydra
+(my-engine-mode-hydra
+(:color blue)
+"Engine mode"
+("b" engine/search-my-blog "blog")
+("m" engine/search-mail "mail")
+("g" engine/search-google "google")
+("e" engine/search-emacswiki "emacswiki")))
+#+END_QUOTE
+[[https://sachachua.com/dotemacs/index.html#org0d11d0e][Sacha Chua's Emacs configuration]]
+Captured On: [2023-07-31 Mon 15:55]
+*** TODO Check Out Emacs Vundo Package
+[[https://github.com/casouri/vundo][casouri/vundo: Visualize the undo tree.]]
+Captured On: [2024-03-24 Sun 16:46]
+*** TODO Custom Elisp: Copy Full Link to This Page to the Kill Ring
+- file - and full path to the file the buffer refers to.
+- http - works on web pages as well
+*** TODO Good Org-Pomodoro Config
+#+BEGIN_QUOTE
+As a person with a short attention span, the Pomodoro technique allows me to maximize my concentration throughout the day. Personally, I do sessions of 25 minutes of concentrated work and 5 minutes of break. Finally, every two hours, I take a 30 minute break. To use the Pomodoro technique with GNU Emacs, the org-pomodoro package is suggested.
+
+(use-package org-pomodoro
+:after org
+:custom
+(alert-user-configuration (quote ((((:category . "org-pomodoro")) libnotify nil))))
+(org-pomodoro-audio-player "/usr/bin/mpv")
+(org-pomodoro-finished-sound "~/audio/pomodoro_finished.mp3")
+(org-pomodoro-format " %s")
+(org-pomodoro-killed-sound "~/audio/pomodoro_killed.mp3")
+(org-pomodoro-long-break-sound "~/audio/pomodoro_long.mp3")
+(org-pomodoro-overtime-sound "~/audio/pomodoro_overtime.mp3")
+(org-pomodoro-short-break-sound "~/audio/pomodoro_short.mp3")
+(org-pomodoro-start-sound "~/audio/pomodoro_start.mp3")
+(org-pomodoro-start-sound-p t))
+#+END_QUOTE
+[[https://github.com/rememberYou/.emacs.d/blob/master/config.org][.emacs.d/config.org at master · rememberYou/.emacs.d]]
+Captured On: [2023-11-19 Sun 17:51]
+*** TODO Implement Org Timer Hydra
+#+BEGIN_QUOTE
+Timers, work clocking, and capturing from anywhere (I use this hydra multiple times each hour).
+
+(defhydra hydra-global-org (:color blue)
+"Org"
+("t" org-timer-start "Start Timer")
+("s" org-timer-stop "Stop Timer")
+("r" org-timer-set-timer "Set Timer") ; This one requires you be in an orgmode doc, as it sets the timer for the header
+("p" org-timer "Print Timer") ; output timer value to buffer
+("w" (org-clock-in '(4)) "Clock-In") ; used with (org-clock-persistence-insinuate) (setq org-clock-persist t)
+("o" org-clock-out "Clock-Out") ; you might also want (setq org-log-note-clock-out t)
+("j" org-clock-goto "Clock Goto") ; global visit the clocked task
+("c" org-capture "Capture") ; Don't forget to define the captures you want http://orgmode.org/manual/Capture.html
+("l" org-capture-goto-last-stored "Last Capture"))
+#+END_QUOTE
+[[https://github.com/abo-abo/hydra/wiki/orgmode][Orgmode · abo-abo/hydra Wiki]]
+Captured On: [2023-11-19 Sun 17:18]
+*** TODO Look Into Emacs-run-command for Any Common Commands
+[[https://bard.github.io/emacs-run-command/demo][Demo – emacs-run-command]]
+Captured On: [2024-03-17 Sun 00:45]
+*** TODO Look Into Ibuffer Sidebar
+[[https://github.com/jojojames/ibuffer-sidebar][jojojames/ibuffer-sidebar: A sidebar for IBuffer]]
+Captured On: [2024-03-02 Sat 16:33]
+*** TODO Look Into Smarter Home/End Keys for Emacs
+[[https://www.emacswiki.org/emacs/download/pc-keys.el][]]
+Captured On: [2023-11-23 Thu 12:22]
+*** TODO Manage External Services Within Emacs With Prodigy
+https://www.jds.work/emacs-prodigy/
+[[https://github.com/rejeep/prodigy.el][rejeep/prodigy.el: Manage external services from within Emacs]]
+Captured On: [2024-03-24 Sun 17:04]
+*** TODO Maybe Just This for Notifications in Emacs?
+#+BEGIN_QUOTE
+Finally, I use org-wild-notifier to get notifications about TODO items in org-agenda.
+
+(use-package org-wild-notifier
+:after org
+:custom
+(alert-default-style 'libnotify)
+(org-wild-notifier-notification-title "Agenda Reminder")
+:config (org-wild-notifier-mode))
+#+END_QUOTE
+[[https://github.com/rememberYou/.emacs.d/blob/master/config.org][.emacs.d/config.org at master · rememberYou/.emacs.d]]
+Captured On: [2023-11-19 Sun 17:49]
+*** TODO Pasting From Clipboard
+This is typically used for inserting copied text from the clipboard.
+Emacs seems to capture this, if so, I need to diassociate ctrl+shift+v from scroll-up-command
+**** 2023-07-18 @ 14:59:44 -0500 What Emacs Help Text Says
+scroll-up-command is an interactive and byte-compiled function defined
+in window.el.gz.
+
+Signature
+(scroll-up-command &optional ARG)
+
+Documentation
+Scroll text of selected window upward ARG lines; or near full screen if no ARG.
+*** TODO Consider implementing vundo package
+#+BEGIN_QUOTE
+(use-package vundo
+ :bind ("C-x u" . vundo)
+ :hook ((vundo-mode . my/vundo-setup))
+ :init
+ (progn
+ (setq vundo-window-max-height 5))
+ :config
+ (progn
+ (setq vundo-glyph-alist vundo-unicode-symbols)
+
+ (defun my/vundo-setup ()
+ "Remove mode-line and header-line."
+ (setq mode-line-format nil)
+ (setq header-line-format nil))))
+#+END_QUOTE
+[[https://github.com/DamienCassou/emacs.d/blob/master/init.el#L352][emacs.d/init.el at master · DamienCassou/emacs.d]]
+Captured On: [2024-04-05 Fri 15:14]
+** Emacs Telegram Backlog [0/2]
+*** TODO Consider Making a Hydra for Telegram
+*** TODO Review Telega Configuration Snippets
+https://github.com/zevlg/telega.el/wiki/Configuration-snippets
+** Emacs Term and Shell Backlog [0/0]
+** Emacs Text Config Backlog [0/8]
+*** TODO Consider Olivetti Settings
+#+BEGIN_QUOTE
+(use-package olivetti
+ :hook (((Info-mode help-mode helpful-mode eww-mode) . olivetti-mode))
+ :init
+ (progn
+ (setq olivetti-body-width 84)))
+#+END_QUOTE
+[[https://github.com/DamienCassou/emacs.d/blob/master/init.el#L352][emacs.d/init.el at master · DamienCassou/emacs.d]]
+Captured On: [2024-04-05 Fri 14:35]
+*** TODO Another (Perhaps Better) Emacs Insert Pair
+#+BEGIN_QUOTE
+Instead of having insert-pair bindings for a fixed list of opening delimiters, I like to have an entire prefix key dedicated to insert-pair. I've chosen C-S-w for the prefix, so C-S-w followed by any opening delimiter will insert the pair, so you can use C-S-w (, C-S-w [, C-S-w {, etc. What I like about this approach is that the paired delimiters can vary by major mode, and I don't need to add key bindings to handle them.
+
+(defvar insert-pair-map
+(let ((map (make-sparse-keymap)))
+(define-key map [t] #'insert-pair)
+map))
+
+(global-set-key (kbd "C-S-w") insert-pair-map)
+#+END_QUOTE
+[[https://www.reddit.com/r/emacs/comments/14r48b8/weekly_tips_tricks_c_thread/][(2) Weekly Tips, Tricks, &c. Thread : emacs]]
+Captured On: [2023-11-18 Sat 09:03]
+*** TODO Check Search Region Functionality in Emacs
+#+BEGIN_QUOTE
+You can search region or user input in duckduckgo using default eww and M-s M-w.
+
+If you prefer google and default OS browser you can implement (or grab existing packages):
+
+(defun web-search ()
+"Search the web for the text in the region.
+If region is active, search the web for the text between
+region beginning and end. Else, prompt the user for a search
+string."
+(interactive)
+(let ((query (if (use-region-p)
+(buffer-substring (region-beginning) (region-end))
+(read-string "Search web for: "))))
+(browse-url (format "https://google.com/search?q=%s"
+(url-hexify-string query)))))
+... bind it somewhere, for example:
+
+(global-set-key (kbd "M-s M-w") 'web-search)
+
+4
+
+
+Reply
+Share
+
+
+
+level 2
+github-alphapapa
+17 days ago
+See options eww-use-browse-url and M-x customize-group RET browse-url RET.
+#+END_QUOTE
+[[https://www.reddit.com/r/emacs/comments/17l7bg8/weekly_tips_tricks_c_thread/][(2) Weekly Tips, Tricks, &c. Thread : emacs]]
+Captured On: [2023-11-18 Sat 07:26]
+*** TODO Check That Your Up/Down/Capitalize Case Functions Are All Tied to Good Keybindings
+#+BEGIN_QUOTE
+The default commands to upcase/downcase/capitalize words are not convenient, for the following reasons:
+
+There are three different commands for upcaseing, for example. The user needs to remember the three commands, their key bindings, and when to use each of them. There should be one command per action: one for upcasing, one for downcasing, and one for capitalizing.
+
+The commands on regions don't have dedicated key bindings and are disabled by default.
+
+The commands like upcase-word depend on the position of pointer inside of the word, so that the result of upcasing "fo^o"is "foO". This packages assumes that you want "FOO".
+
+One needs to use arguments for commands like upcase-word to make them correct the words that one has just written and only one word can be adjusted in this way.
+
+Here are the commands that try to fix these flaws:
+
+fix-word-upcase
+fix-word-downcase
+fix-word-capitalize
+I propose replacing of the built-ins with these new commands:
+
+(global-set-key (kbd "M-u") #'fix-word-upcase)
+(global-set-key (kbd "M-l") #'fix-word-downcase)
+(global-set-key (kbd "M-c") #'fix-word-capitalize)
+#+END_QUOTE
+[[https://github.com/mrkkrp/fix-word][mrkkrp/fix-word: Transform words in Emacs (upcase, downcase, capitalize, etc.)]]
+Captured On: [2023-11-18 Sat 07:24]
+*** TODO Emacs Insert Pair
+#+BEGIN_QUOTE
+28
+
+
+For parens you can do M-(. For brackets/braces/quotes you could do:
+
+(global-set-key (kbd "M-[") 'insert-pair)
+(global-set-key (kbd "M-{") 'insert-pair)
+(global-set-key (kbd "M-\"") 'insert-pair)
+Note that if you don't have a region highlighted, it will just insert the pair of whatevers and put the cursor in between them. Also handy for deleting matching whatevers is
+
+(global-set-key (kbd "M-)") 'delete-pair)
+EDIT:
+
+Good point in the comments about overriding backward-paragraph. You could bind it to C-{, which might interfere with something in a major mode. insert-pair takes the last key and does a lookup to see what pair to insert, so if you don't want to bind it to something-{ you could bind to this function instead:
+
+(defun my-insert-braces ()
+(interactive)
+(if (region-active-p)
+(insert-pair 1 ?{ ?})
+(insert "{}")
+(backward-char)))
+Share
+Improve this answer
+Follow
+
+#+END_QUOTE
+[[https://stackoverflow.com/questions/2951797/wrapping-selecting-text-in-enclosing-characters-in-emacs][Wrapping selecting text in enclosing characters in Emacs - Stack Overflow]]
+Captured On: [2023-11-18 Sat 09:02]
+*** TODO Emacs Narrow to Region and Clone Indirect
+#+BEGIN_QUOTE
+I have enjoyed my own dwim version of a narrow-to-region + clone-buffer-indirect command I found online for quite some time now.
+Earlier this week I realized most times I select the current function or paragraph before using the command, so I could make that the default case when there's no region. I came up with this:
+
+;; Inspired by https://demonastery.org/2013/04/emacs-narrow-to-region-indirect/
+;; and modified to DWIM. Also use `pop-to-buffer' instead of `switch-to-buffer'
+(defun hoagie-clone-indirect-dwim (&optional arg)
+"Create an indirect buffer, narrow it to defun or active region.
+If ARG, don't narrow."
+(interactive "P")
+(unless (or (use-region-p)
+arg)
+(mark-defun))
+(let ((start (use-region-beginning))
+(end (use-region-end))
+;; we'll pop the buffer manually
+;; to clear the region
+(buf (clone-indirect-buffer nil nil)))
+(deactivate-mark)
+(with-current-buffer buf
+(when (and start end)
+(narrow-to-region start end)
+(deactivate-mark))
+(pop-to-buffer buf))))
+And it covers the same cases as before (thanks to the prefix arg).
+I bound it in one of my custom keymaps to c (for "clone").
+#+END_QUOTE
+[[https://www.reddit.com/r/emacs/comments/16tes2a/weekly_tips_tricks_c_thread/][(2) Weekly Tips, Tricks, &c. Thread : emacs]]
+Captured On: [2023-11-18 Sat 08:21]
+*** TODO Investigate Ialign for a visual align-regexp
+#+BEGIN_QUOTE
+ialign
+
+(use-package ialign
+:bind ("C-c {" . ialign))
+#+END_QUOTE
+[[https://github.com/jwiegley/dot-emacs/blob/master/init.org][dot-emacs/init.org at master · jwiegley/dot-emacs]]
+Captured On: [2023-07-31 Mon 16:57]
+*** TODO Open Line Above/Below in Emacs
+#+BEGIN_QUOTE
+Open line below/above line in VIM, stolen and slighty modified from here https://www.emacswiki.org/emacs/OpenNextLine I use electric-indent-mode so I had no use for indent-according-to-mode.
+
+(defun my/open-line-above ()
+"Insert an empty line above the current line."
+(interactive)
+(beginning-of-line)
+(open-line 1))
+
+(defun my/open-line-below (arg)
+"Insert an empty line below the current line.
+
+With a prefix ARG insert line above the current line."
+(interactive "P")
+(if arg
+(my/open-line-above)
+(end-of-line)
+(open-line 1)
+(forward-line 1)))
+
+;; open line (above/below)
+(global-set-key (kbd "C-o") 'my/open-line-below)
+(global-set-key (kbd "M-o") 'my/open-line-above)
+#+END_QUOTE
+[[https://www.reddit.com/r/emacs/comments/14r48b8/weekly_tips_tricks_c_thread/][(2) Weekly Tips, Tricks, &c. Thread : emacs]]
+Captured On: [2023-11-18 Sat 09:05]
+** Emacs Tramp Backlog [0/1]
+*** TODO [#C] Review Emacs Wiki and Gnu Documentation on Tramp Mode
+[[https://www.emacswiki.org/emacs/TrampMode#toc12][EmacsWiki: Tramp Mode]]
+https://www.gnu.org/software/tramp/
+** Emacs UI Config Backlog [0/2]
+*** TODO Dedicated Buffers (Emacs won't overwrite/load buffers here)
+[[https://github.com/emacsorphanage/dedicated/tree/f47b504c0c56fa5ab9d1028417ca1f65a713a2f0][emacsorphanage/dedicated at f47b504c0c56fa5ab9d1028417ca1f65a713a2f0]]
+Captured On: [2023-07-31 Mon 16:23]
+*** TODO Rotate Layout in Emacs
+[[https://github.com/daichirata/emacs-rotate/blob/master/rotate.el][emacs-rotate/rotate.el at master · daichirata/emacs-rotate]]
+Captured On: [2023-11-23 Thu 12:27]
+** Emacs UI Navigation Backlog [0/3]
+*** TODO Avy Hydra
+#+BEGIN_QUOTE
+Avy
+Avy is a damned fast way to jump to characters, (sub-)words, and lines. In this hydra I combine it with link-hint, a package based on Avy used to jump-to and open URLs:
+
+(use-package avy
+:config
+(use-package link-hint)
+(global-set-key (kbd "M-g g") #'avy-goto-line)
+(defhydra hydra-avy (global-map "M-g" :color blue)
+"avy-goto"
+("c" avy-goto-char "char")
+("C" avy-goto-char-2 "char-2")
+("w" avy-goto-word-1 "word")
+("s" avy-goto-subword-1 "subword")
+("u" link-hint-open-link "open-URI")
+("U" link-hint-copy-link "copy-URI")))
+#+END_QUOTE
+[[https://ericjmritz.wordpress.com/2015/10/14/some-personal-hydras-for-gnu-emacs/][Some Personal Hydras for GNU Emacs – One More Game-Dev and Programming Blog]]
+Captured On: [2023-11-19 Sun 16:52]
+*** TODO Emacs Zoom to Window
+[[https://github.com/emacsorphanage/zoom-window][emacsorphanage/zoom-window: Zoom and Unzoom window]]
+Captured On: [2023-11-18 Sat 08:46]
+*** TODO Window Moving Hydra To Implement in Emacs
+#+BEGIN_QUOTE
+Deluxe Window-moving
+Includes window resizing, winner undo/reset, follow mode, vertical help
+
+(defhydra hydra-window ()
+"
+Movement^^ ^Split^ ^Switch^ ^Resize^
+----------------------------------------------------------------
+_h_ ← _v_ertical _b_uffer _q_ X←
+_j_ ↓ _x_ horizontal _f_ind files _w_ X↓
+_k_ ↑ _z_ undo _a_ce 1 _e_ X↑
+_l_ → _Z_ reset _s_wap _r_ X→
+_F_ollow _D_lt Other _S_ave max_i_mize
+_SPC_ cancel _o_nly this _d_elete
+"
+("h" windmove-left )
+("j" windmove-down )
+("k" windmove-up )
+("l" windmove-right )
+("q" hydra-move-splitter-left)
+("w" hydra-move-splitter-down)
+("e" hydra-move-splitter-up)
+("r" hydra-move-splitter-right)
+("b" helm-mini)
+("f" helm-find-files)
+("F" follow-mode)
+("a" (lambda ()
+(interactive)
+(ace-window 1)
+(add-hook 'ace-window-end-once-hook
+'hydra-window/body))
+)
+("v" (lambda ()
+(interactive)
+(split-window-right)
+(windmove-right))
+)
+("x" (lambda ()
+(interactive)
+(split-window-below)
+(windmove-down))
+)
+("s" (lambda ()
+(interactive)
+(ace-window 4)
+(add-hook 'ace-window-end-once-hook
+'hydra-window/body)))
+("S" save-buffer)
+("d" delete-window)
+("D" (lambda ()
+(interactive)
+(ace-window 16)
+(add-hook 'ace-window-end-once-hook
+'hydra-window/body))
+)
+("o" delete-other-windows)
+("i" ace-maximize-window)
+("z" (progn
+(winner-undo)
+(setq this-command 'winner-undo))
+)
+("Z" winner-redo)
+("SPC" nil)
+)
+#+END_QUOTE
+[[https://github.com/abo-abo/hydra/wiki/Window-Management][Window Management · abo-abo/hydra Wiki]]
+Captured On: [2023-11-19 Sun 17:16]
+** Emacs UI-Theme Backlog [0/2]
+*** TODO Recreate Distinguished-theme.
+Call it Dupre or something if you like.
+*** TODO Theming for Emacs
+#+BEGIN_QUOTE
+
+;;; <OPTIONAL THEMING>
+
+;; Modus-themes are just excellent, easy to read and work really well
+;; with code as well as text (org-mode, markdown).
+(use-package modus-themes
+:ensure t
+:config
+(setq modus-themes-org-blocks 'gray-background
+modus-themes-fringes 'subtle
+modus-themes-italic-constructs t
+modus-themes-bold-constructs t
+modus-themes-syntax '(alt-syntax)
+modus-themes-hl-line '(intense)
+modus-themes-paren-match '(intense)
+modus-themes-mode-line '(borderless))
+(setq modus-themes-headings
+(quote ((1 . (background overline variable-pitch 1.4))
+(2 . (overline rainbow variable-pitch 1.25))
+(3 . (overline 1.1))
+(t . (monochrome))))))
+
+;; Running modus-themes depending on the time of the day. <ATTENTION>
+;; You need to set the longitude and latitude to your city's for this
+;; to be accurate.
+(use-package solar
+:ensure nil
+:custom
+;; Brussels ;)
+(calendar-latitude 50.85)
+(calendar-longitude 4.35))
+
+(use-package circadian
+:ensure t
+:after solar
+:config
+(setq circadian-themes '((:sunrise . modus-operandi)
+(:sunset . modus-vivendi)))
+(circadian-setup))
+#+END_QUOTE
+[[https://gist.github.com/Nathan-Furnal/b327f14e861f009c014af36c1790ec49][Trimmed down python setup for Emacs. This is a basic `init.el` file for Python, you can pick the bits you like.]]
+Captured On: [2023-10-16 Mon 14:20]
+** Emacs VC Config Backlog [0/9]
+*** TODO Abridge-Diff for Long Magit Diff Hunks
+[[https://github.com/jdtsmith/abridge-diff][jdtsmith/abridge-diff: Emacs package for refining diff hunks with very long lines (as in LaTeX files)]]
+Captured On: [2023-10-27 Fri 11:08]
+*** TODO [#A] Figure Out VC Installs and Add Snippet
+**** TODO Investigate Vc-install Failure With Wttrin Config
+**** TODO Look Into Package-vc-install
+[[https://tony-zorman.com/posts/package-vc-install.html][Exploring package-vc-install · Tony Zorman]]
+Captured On: [2023-10-20 Fri 13:29]
+**** TODO Look Into Vc-use-package
+[[https://github.com/slotThe/vc-use-package][slotThe/vc-use-package: Primitive package-vc integration for use-package]]
+Captured On: [2023-10-20 Fri 13:30]
+**** TODO Reddit Discussion on Package-vc-install
+[[https://www.reddit.com/r/emacs/comments/z9i4ce/exploring_packagevcinstall_as_an_alternative_to/][(4) Exploring package-vc-install as an alternative to Quelpa : emacs]]
+Captured On: [2023-10-20 Fri 13:32]
+**** TODO Video on Vc-install Package
+[[https://www.youtube.com/watch?v=uaXgvQCcEl0][(1) Emacs 29 package-vc-install install packages from github - YouTube]]
+Captured On: [2023-10-20 Fri 13:31]
+*** TODO Git Gutter Hydra Example
+#+BEGIN_QUOTE
+This one for git-gutter is very handy
+
+(defhydra hydra-git-gutter (:body-pre (git-gutter-mode 1)
+:hint nil)
+("n" git-gutter:next-hunk "next hunk")
+("p" git-gutter:previous-hunk "previous hunk")
+("h" (progn (goto-char (point-min)) (git-gutter:next-hunk 1)) "first hunk")
+("l" (progn (goto-char (point-min)) (git-gutter:previous-hunk 1)) "last hunk")
+("<SPC>" git-gutter:popup-hunk "popup hunk")
+("s" git-gutter:stage-hunk "stage hunk")
+("r" git-gutter:revert-hunk "revert hunk")
+("q" nil "quit"))
+#+END_QUOTE
+[[https://www.reddit.com/r/emacs/comments/gr2zaj/what_are_your_useful_hydras/][(2) What are your useful hydras? : emacs]]
+Captured On: [2024-03-09 Sat 13:36]
+*** TODO Investigate git-walktree for browsing your git repos
+[[https://github.com/10sr/git-walktree-el/tree/a1a5490b89d193724ec637818baf2d8edf97c638][10sr/git-walktree-el at a1a5490b89d193724ec637818baf2d8edf97c638]]
+Captured On: [2023-07-31 Mon 17:07]
+*** TODO Investigate Vdiff and Magit-vdiff packages
+#+BEGIN_QUOTE
+
+vdiff
+
+(use-package vdiff
+:commands (vdiff-files
+vdiff-files3
+vdiff-buffers
+vdiff-buffers3))
+#+END_QUOTE
+[[https://github.com/jwiegley/dot-emacs/blob/master/init.org][dot-emacs/init.org at master · jwiegley/dot-emacs]]
+Captured On: [2023-07-31 Mon 17:29]
+*** TODO Understand Git Rebase and Squash Workflow in Magit
+#+BEGIN_QUOTE
+This process can be streamlined significantly — I thought that was what I was about to read — with the magit-commit-fixup/squash commands (c f and c s).
+
+I use those all the time. When you have staged your fixup changes, do c f and then it offers you the log to select which commit you're fixing up (with .). Then, e.g. for original commit title "original commit", it'll make your new commit with title "fixup! original commit".
+
+Subsequently when you interactive rebase, git will reorder and flag the fixups (and squashes) automatically, providing you have the rebase.autosquash config setting set to true. i.e. in ~/.gitconfig:
+
+[rebase]
+autosquash = true
+(Edited: case typos)
+
+level 2
+9 yr. ago
+You mean c f and c s, lowercase c. The difference here is that this only modifies the latest commit with the currently staged changes. Very handy, but if you want to rewrite history (reword, fixup, reorder commits, edit commits), you will need interactive rebase.
+
+level 3
+9 yr. ago
+Oh right, sorry I screwed up the case thing (edited)
+
+However, I don't know what you mean about the latest commit. This isn't for amending the latest commit (c a), c f and c s is for adding fixup or squash commits for any existing commit.
+
+It's not a replacement for interactive rebasing, it's just a more streamlined way to do it.
+#+END_QUOTE
+[[https://www.reddit.com/r/emacs/comments/2q7ohw/til_how_to_squash_commits_using_magit/][(4) TIL How to Squash Commits using Magit : emacs]]
+Captured On: [2023-10-23 Mon 06:15]
+
+*** TODO Warn When Leaving Dirty Repository
+[[https://github.com/thisirs/vc-check-status#vc-check-status][thisirs/vc-check-status: Package that warns you when quitting emacs and leaving a repository dirty.]]
+Captured On: [2024-02-29 Thu 10:12]
+*** TODO Forge Config
+#+BEGIN_QUOTE
+(use-package forge
+ :demand t
+ :after magit
+ :hook (forge-post-submit-callback . my/forge-start-timer-for-draft-pullreq)
+ :config
+ (progn
+ (setq-default forge-buffer-draft-p t)
+
+ (defun my/forge-start-timer-for-draft-pullreq (pullreq &rest _)
+ "Start a `tmr' timer if PULLREQ is draft."
+ (when (map-elt pullreq 'draft)
+ (when-let* ((url (map-elt pullreq 'url))
+ (minutes (cond
+ ((string-match-p "foretagsplatsen/monitor" url) 15)
+ (t 10))))
+ (require 'tmr)
+ (tmr minutes (format "Check draft %s" url) t))))))
+
+(use-package forge-topic
+ :init
+ (progn
+ (setq forge-topic-list-limit '(60 . -1))))
+#+END_QUOTE
+[[https://github.com/DamienCassou/emacs.d/blob/master/init.el#L352][emacs.d/init.el at master · DamienCassou/emacs.d]]
+Captured On: [2024-04-05 Fri 15:18]
+*** TODO Magit Config to Review
+#+BEGIN_QUOTE
+(use-package magit
+ :bind ((
+ :map magit-mode-map
+ ("M-w" . magit-copy-section-value)))
+ :init
+ (progn
+ (setq magit-diff-refine-hunk t)
+ (setq magit-process-find-password-functions '(magit-process-password-auth-source))
+ (setq magit-branch-prefer-remote-upstream '("master"))
+ (setq magit-branch-adjust-remote-upstream-alist '(("origin/master" "master")
+ ("origin/main" "main")))
+ (setq magit-module-sections-nested nil)
+ (setq magit-display-buffer-function #'magit-display-buffer-same-window-except-diff-v1)
+ (setq magit-no-confirm '(amend-published trash))
+ (setq magit-revision-insert-related-refs nil)
+ (setq magit-revision-show-gravatars t)
+ (setq magit-clone-set-remote.pushDefault t))
+ :config
+ (progn
+ ;; Enable magit-clean
+ (put 'magit-clean 'disabled nil)
+
+ ;; Add modules in magit status buffer:
+ (magit-add-section-hook 'magit-status-sections-hook
+ 'magit-insert-modules
+ 'magit-insert-unpulled-from-upstream)
+
+ ;; Only show the module sections I'm interested in
+ (with-eval-after-load "magit-submodule"
+ (remove-hook 'magit-module-sections-hook 'magit-insert-modules-overview)
+ (remove-hook 'magit-module-sections-hook 'magit-insert-modules-unpulled-from-pushremote)
+ (remove-hook 'magit-module-sections-hook 'magit-insert-modules-unpushed-to-upstream)
+ (remove-hook 'magit-module-sections-hook 'magit-insert-modules-unpushed-to-pushremote))
+
+ (transient-replace-suffix 'magit-commit 'magit-commit-autofixup
+ '("x" "Absorb changes" magit-commit-absorb))
+
+ (dir-locals-set-class-variables 'my/magit-huge-git-repository
+ '((magit-status-mode
+ .
+ ((eval . (magit-disable-section-inserter 'magit-insert-tags-header))
+ (eval . (magit-disable-section-inserter 'magit-insert-untracked-files))
+ (eval . (magit-disable-section-inserter 'magit-insert-modules))))))
+
+ (let ((huge-repos
+ '("~/Documents/projects/nix/nixpkgs-master"
+ "~/Documents/projects/nix-system/nixpkgs/")))
+ (dolist (repo huge-repos)
+ (dir-locals-set-directory-class
+ (expand-file-name repo)
+ 'my/magit-huge-git-repository)))))
+
+(use-package magit-diff
+ :bind (
+ :map magit-diff-section-map
+ ;; disable binding that I use for begining of buffer
+ ("C-x a" . nil)))
+
+(use-package magit-extras
+ :demand (project magit))
+
+(use-package magit-tbdiff
+ :demand t
+ :after magit)
+#+END_QUOTE
+[[https://github.com/DamienCassou/emacs.d/blob/master/init.el#L352][emacs.d/init.el at master · DamienCassou/emacs.d]]
+Captured On: [2024-04-05 Fri 15:19]
+** Emacs Window/Buffer Config Backlog [0/1]
+*** TODO Investigate Using Popper for Window Management
+Demo: https://www.youtube.com/watch?v=E-xUNlZi3rI
+Repo: https://github.com/karthink/popper
+* Emacs Config Resolved / Completed
+* Emacs Config Notes
+** 2023-11-03 Fri @ 18:28:36 -0500 Break Code Into Divisions
+CLOSED: [2023-11-03 Fri 18:28]
+** 2023-11-01 Wed @ 10:33:34 -0500 Decision: no need for specific order in init.el
+Question: Is there any reason to keep associated functionality adjacent in the init.el list?
+Answer: No. In fact, I should prevent the need for ordering. Ordering constraints should be considered a bug.
+*** Functionality related to interdependent workflows together: No
+Example: Org-agenda leverages org-roam project files in building its agenda.
+Does that mean they should be adjacent?
+
+I can adjust this anyway I want. It's best to have these loosely coupled. Since this is the target, I'm going to say I should not specify an order, but when I discover a hard dependency, I should indicate that in the code with the use-package :after clause.
+*** Most frequently used functionality: No
+I believe this org-reorg project may take time and I will want to use org functionality to take notes without having to launch another version of Emacs from the main branch.
+Given this, I should probably do the work in the order I use it, but that doesn't mean it must be ordered that way in init.el.
+** 2023-11-01 Wed @ 09:59:35 -0500 General Strategy
+All changes will happen in the 'org-reorg' branch, allowing use of Emacs without breakages from changes.
+
+Here's are the major divisions, in priority order.
+org-config ;; general settings, keybindings, org-contrib
+org-appearance-config ;; bullets, faces, etc.
+org-agenda-config ;; org-agenda, org-superagenda, org-todo
+org-babel-config ;; org-babel languages/settings, org-tempo
+org-capture-config ;; capture templates, refiling, org-web-clipper
+org-drill-config ;; org-drill (already broken out)
+org-export-config ;; org-export
+org-roam-config ;; org-roam (already broken out)
+
+Note: org-mode will be loaded via use-package with a delay of .5 seconds. All other org-* modules will be wrapped in the (with-eval-after-load) function so the code is guaranteed to load after org-mode itself. This avoids some current errors of trying to add a binding to a keymap before it's been created, or similar.
+* Emacs Config Testing Notes
+** Release Resting Checklist
+updated Sunday, April 07, 2024 at 12:44:55 PM CDT
+*** TODO No Open Work
+*** TODO WIP Code Empty/Disabled
+*** TODO Emacs Config Inbox Zero
+*** TODO Check for Listed Keys
+*** TODO Run all ERT Tests
+*** TODO Perf Testing: Sub-Second Launch Time
+*** TODO Successful Hands-Off Launch from Git Clone
+*** TODO Successful Hands-Off Launch from Archsetup
+*** TODO Develop Branch Cleanly Merged Into Main
+*** TODO Main Branch Pushed to Github and git.cjennings.net
+*** TODO 2 Week Scenario Testing / Bug Fixing
+*** TODO Mark Release as DONE and version Create Tag on Repositories
+* Emacs Config Examples
+** Damien Cassou's Emacs Config
+https://github.com/DamienCassou/emacs.d
+https://raw.githubusercontent.com/DamienCassou/emacs.d/master/init.el
+** Jon Wiegley's Emacs Config
+[[https://github.com/jwiegley/dot-emacs/blob/master/init.org][dot-emacs/init.org at master · jwiegley/dot-emacs]]
+Captured On: [2023-11-01 Wed 12:01]
+** Snosov1's Emacs Config
+[[https://github.com/snosov1/dot-emacs][snosov1/dot-emacs: Emacs configuration]]
+Captured On: [2023-07-16 Sun 09:21]
+** Steve Purcell's Emacs Config
+[[https://github.com/purcell/emacs.d][purcell/emacs.d: An Emacs configuration bundle with batteries included]]
+Captured On: [2023-11-04 Sat 18:48]
+** Protesilaos Stavrou's Emacs Config
+[[https://git.sr.ht/~protesilaos/dotfiles/tree/master/item/emacs/.emacs.d][~protesilaos/dotfiles: emacs/.emacs.d/ - sourcehut git]]
+Captured On: [2023-11-04 Sat 18:51]
+** Brett Lempereur's Emacs Config
+[[https://github.com/brett-lempereur/.emacs.d][brett-lempereur/.emacs.d: Portable Emacs configuration]]
+Captured On: [2023-11-04 Sat 19:24]
+** Bodhizar Batsov's Emacs Configuration
+[[https://github.com/bbatsov/emacs.d][bbatsov/emacs.d: My personal Emacs configuration]]
+Captured On: [2023-11-04 Sat 23:30]
+** Rememberyou's Emacs Config
+[[https://github.com/rememberYou/.emacs.d/blob/master/config.org][.emacs.d/config.org at master · rememberYou/.emacs.d]]
+Captured On: [2023-11-18 Sat 07:07]
+** ThoughtBot's dotfiles
+[[https://github.com/thoughtbot/dotfiles][thoughtbot/dotfiles: A set of vim, zsh, git, and tmux configuration files.]]
+Captured On: [2024-03-14 Thu 04:36]
+* Emacs FAQ/Reference
+** Testing REST API with Emacs
+[[https://emacs.stackexchange.com/questions/2427/how-to-test-rest-api-with-emacs][package - How to test REST API with Emacs? - Emacs Stack Exchange]]
+Captured On: [2023-11-01 Wed 15:58]
+** Emacs Keybinding to Lambda
+#+BEGIN_QUOTE
+Emacs Lisp: Keybinding to Lambda
+
+# The Problem
+if you simply bind a key to a lambda with ‘define-key’, the key will be reported by describe-bindings with a ??
+
+For instance
+
+#+begin_src emacs-lisp :tangle no
+ (define-key global-map [pause]
+ '(lambda () "say foo" (interactive) (message "foo")))
+#+end_src
+
+results in
+
+<pause> ??
+
+# The Solution
+
+A solution is to give the lambda a name describing its function. This wrapper can be used to turn the documentation string into a
+name …
+
+#+begin_src emacs-lisp :tangle no
+ (defun lambda-key (keymap key def)
+ "Wrap`define-key' to provide documentation."
+ (set 'sym (make-symbol (documentation def)))
+ (fset sym def)
+ (define-key keymap key sym))
+#+end_src
+
+Then after …
+
+#+begin_src emacs-lisp :tangle no
+ (lambda-key global-map [pause]
+ '(lambda () "say foo" (interactive) (message "foo")))
+#+end_src
+
+… the key binding will be described like this:
+
+<pause> say foo
+
+Since ‘lambda-key’ has the same signature as ‘define-key’, you can quickly switch between them. (Tested with Emacs 25.2)
+
+[[https://www.emacswiki.org/emacs?search=%22DocumentingKeyBindingToLambda%22][DocumentingKeyBindingToLambda]]
+
+#+END_QUOTE
+[[][]]
+Captured On: [2023-11-27 Mon 18:15]
+** How do I rebind some keys to another keybinding?
+This rebinding intends to shorten a longer keybinding sequence to a shorter one.
+Note: this leaves the original longer keybinding in place
+#+begin_src emacs-lisp
+ ;; disabled, but leaving for reference on how to rebind keys to another binding
+ ;; (define-key global-map (kbd "C-c g") (kbd "C-c c g"))
+#+end_src
+** How to set fonts for specific ranges of Unicode codepoints
+#+BEGIN_QUOTE
+(when (display-graphic-p)
+(set-fontset-font "fontset-default"
+'(#xe000 . #xe07d)
+"FreeMonoTengwar"))
+#+END_QUOTE
+[[https://github.com/chrisbouchard/dotfiles/blob/9bfbe4566520d9e5d8ca998901e120564982d5eb/home/.spacemacs#L606][dotfiles/home/.spacemacs at 9bfbe4566520d9e5d8ca998901e120564982d5eb · chrisbouchard/dotfiles]]
+Captured On: [2023-11-04 Sat 17:08]
+** WebKit Downgrade Instructions for Emacs
+#+BEGIN_QUOTE
+Hi! I'm using Arch Linux and I've finally managed to downgrade webkit2gtk and recompile emacs 29. This is what I've done:
+
+I've installed downgrade using yay from AUR
+
+I've downgraded webkit2gtk to 2.40
+
+$ sudo pacman -Qi webkit2gtk
+Name : webkit2gtk
+Version : 2.40.5-2
+Description : Web content engine for GTK
+Architecture : x86_64
+URL : https://webkitgtk.org
+Licenses : custom
+Groups : None
+Provides : libjavascriptcoregtk-4.0.so=18-64 libwebkit2gtk-4.0.so=37-64
+...
+3) I've recompiled emacs using:
+
+$ ./configure -C --prefix=$HOME/.local/opt/emacs-29 --with-json --with-xwidgets --with-mailutils --with-tree-sitter --with-native-compilation --with-imagemagick --with-gif --with-jpeg --with-png --with-xml2 --with-tiff --with-libsystemd --with-modules
+$ make -j 4 install
+4) Check if emacs binary loads the right shared object:
+
+$ ldd ~/.local/opt/emacs-29/bin/emacs | grep webkit
+libwebkit2gtk-4.0.so.37 => /usr/lib/libwebkit2gtk-4.0.so.37 (0x00007fa2d9400000)
+5) Started emacs:
+
+~/.local/opt/emacs-29/bin/emacs --with-profile doom
+Now I can use xwebkit again. I hope this is useful.
+#+END_QUOTE
+[[https://www.reddit.com/r/emacs/comments/17g6npv/xwidgetwebkit_has_started_crashing_emacs_sessions/][(1) `xwidget-webkit` has started crashing Emacs sessions : emacs]]
+Captured On: [2024-03-20 Wed 09:11]
+** Getting Emacs webkit to work on Arch Linux
+
+TLDR: add
+
+#+begin_src sh
+-xrm "emacs.synchronous: true"
+#+end_src
+
+to the end of the emacs startup command
+*** from https://bbs.archlinux.org/viewtopic.php?id=294283
+
+While I was reading through this thread (https://lists.gnu.org/archive/html/bug- … 00651.html) I saw this CLI arguments:
+
+-xrm "emacs.synchronous: true"
+When I run Emacs (with xwidget-webkit support enabled) like this:
+
+~/.local/opt/emacs/bin/emacs --init-directory ~/.config/emacs -xrm "emacs.synchronous: true"
+xwidget-webkit works!