I like the default behavior of magit, but after increasing font size it
suddenly started opening from bottom instead of from the right.
There's probably some config somewhere to decide this (probably
line-length limit), but for now I'm not going to spend much effort on
it. doom's popup rule macro is good enough™.
- Comments are brownish rather than yellow
- Strings are more intense green
I'm digging the comments, but strings are sort of too pronounced
compared to rest of the code. Might want to revert to orignal
green-cooler if it gets distracting.
Some component in ox-zola+ox-hugo+zola was making markdown not be
rendered properly to HTML. I had no time to figure it out so Hugo was
it.
ox-hugo is well maintained by Kaushal Modi and others, has much more
widespread use, is well documented, and Hugo even uses it automatically!
Overall, I'm liking the result, and keeping it.
I moved my blog to Hugo. Zola's markdown rendering wasn't really
working, and I didn;t want to debug that at this moment.
Hugo worked much much better, with no intermediary step for converting
to md, as it supports orgmode by default.
partly inspired by
https://christiantietze.de/posts/2023/01/modus-themes-v4-changes/
- Use variable pitch font in some org-agenda constructs
- Enable mixed-fonts
- Use medium and italic for prompts
- use medium weight instead of semibold for default org headings
- Use :custom keyword in use-package config
This is a major, breaking change.
Nearly all the variables are gone, and face-by-face override is
necessary. Modus-themes are now a theme-engine with some reasonable
defaults. This makes it more customizable, but also needs more tweaking
than before and knowing more about Emacs faces.
Anyway, I got to a reasonably close approximation of what I had before,
but there are things remaining. Namely, completions, org-blocks,
org-agenda bolds and hl-line brightness.
But, for now, its mostly good enough.
This is the ultimate solution for weird intricacies of Rust programs
or SBCL needing OpenSSL for compiling stuff, or pre-compiled internet
binaries (not that they're good..) needing specific libs in specific
places that don't exist on NixOS.
While this makes the system less good, it does make it a more
accommodating citizen in the Unix land. This is also a lot more
declarative than any other system out there, so that's an added benefit.
If this works out as advertised, this is going to change a lot of things.
- Add arxiv-citation
- Download arxiv PDFs
- Automatically add bibtex entry to specified file
- Minor modifications to Citar config
- Configure citar-org-roam to not use any subdirectory
The commit line length in Doom by default is 80. However, because of my
current laptop screen and split screen editing of commit message in
magit is configured, the line endings happen very awkwardly with single
character on newline. This is generally not an issue, but its just a
nagging thing that I personally do not like.
One of the obvious fix is to simply set the commit message line length
limit to 72 characters as does Linux kernel (and hopefully other GNU
projects, possibly including Emacs itself). This doesn't make too much
difference in usability, while preserving the aesthetics on my laptop
display.
Because this utilizes both the hook and a check for buffer name, this
should not modify the line length for any other buffer and remain at 80.
Like Prot, I have concerns on use-package DSL becoming a problem, but for now, I
find the declarative nature of it to be a good thing and consider it worthwhile.
Its a better more ergonomic replacement for isearch (C-s/C-r) commands.
In cursory usage I like it, its use is a bit less in collapsed Org content, but
otherwise the UX is well thought out.
I've never used them since adding them, and the plans to publish it regularly
did not materialize. So rather than have these useless properties cluttering
space (especially apparent because I no longer hide them, thanks to notes in
org-mode), I just remove them.
By default, Org binds C-' to cycling org-agenda-files, which is useless for me,
since my agenda is collected from hundreds of files.
Since discovering imenu, I am probably going to use it more going forward, and
making this experience uniform across all modes, as is The Emacs Way™, it only
makes sense to reset the keybinding here.
text-properties are still slightly faster than overlays, but over long enough
timeline (Emacs 32+) they will probably be deprecated in favor of fast overlay
implementation in newer Emacs versions.
Since the speed it pretty much the same (I do not have very large Org buffers),
it makes sense to just keep the forward compatible behavior.
I like the alternating half-screen windows from original magit compared to the
full page doom behavior that wastes right side of screen and overlaps the commit
message and changes.
This is better IMO, and I remember I missed it quite dearly after switching to
doom first time around. Nice to have it back :)
Instead of popping a tiny buffer from the bottom, it now opens a buffer from
right, taking half the screen space. This is more comfortable for me right now,
especially since my programs tend to be small and do not extend to the right too
much.
use-package allows specifying dependencies and only loading org-modern after
org-mode is loaded, and pretty much ensure global activation of org-modern
immediately after org-mode is loaded.
Org-modern is a new package by minad (of consult, vertico and marginalia). The
package attempts to make org-mode a bit more pretty and nicer looking, but
instead of using images or heavy regex overrides, it uses box properties. It
kinda fits better in Emacs aesthetics IMO and looks kinda nice and clean.
Instead of colored text abound everywhere, the boxes make spotting things
slightly easier, although reduces text size on those boxes might be annoying
down the road.
Although cleaner and faster than its other brethren, there still is a
performance impact. It is noticeable when doing for eg. big scrolling fast, and
that might just make me hesitant to use it long term, but for now, I'm going to
give it honest and good test run for a while.
CATEGORY property is picked to show in agenda instead of filename.
since my filenames are quite long and contain unhelpful numbers in front, this
makes the agenda a lot cleaner. It is not perfect, but its better than before.
Since discovering how easy it is to add timestamped notes to headings, I have
been using that. It is quite convenient, and might just save me from
consolidating lot of daily notes.
But the notes are added under LOGBOOK drawer and since it does not open
automatically, I lose the sight of how extensive the notes are. This variable
opens all the drawers, and I'll have to see how much I like that, but its a
decent compromise for now.
While it is generally nice, I don't use a lot of tabs (yet) and it wastes space
on shorter tab names and crops longer tab names, making both scenarios fairly
problematic.
This is in hopes that the ABI mismatch will be less likely, but it still happens
sometimes. Anyway, since tree-sitter needs a dynamic module for now, its better
to include all the related packages from NixOS.
This is to test out the new fast overlays in 29. Apparemtly Ihor's
text-properties based folding is fast, but takes large files to be really
noticeable. But overlays have been made nearly (equally?) as fast now, and the
variable doc says they are probably more compatible with 3rd party packages.
Now that Music collection from WSL can be accessed by Strawberry directly from
filesystem, it is not necessary to keep navidrome service around any more.
Because Elixir dev env issues are killing motivation for Neha, we are evaluating
Rust.
We know the trade-offs, and this is just an evaluation, to see how things end up
with improved dev experience.
- Add keybinding and hack around limitation of package loading detection
- Change C-SPC 1 keybinding title to "news" from elfeed
- Save matrix session to avoid logging in too often
Due to some weird combination of use-package and doom-emacs' org-roam module,
the usual keywords from use-package are not working (:custom, :init, :config
etc).
But this weird ordering appears to be working, so this is what we shall keep.
..and shave off half a second on startup time. Considering this is on SSD, this
half second is actually fairly impressive, and brings load time consisitently
below 4 seconds.
This is bit of an experiment, so see all the headings (including sub-headings)
by default, but none of the content, kind of giving a complete outline of the
document, but we'll see if I want to keep it down the road
Because apparently setting some variables before org is loaded meant their
default values were set by the mode and not the config.
Setting them after loading the mode worked as expected, as was the working
config before.
Make things more tidy and arrange them where they belong, with mode specific
config neatly nestled inside use-package for that mode or package forming nice
islands of declarative config.
It supposedly adds a few niceties, which I'm not sure I need, but it
automatically downloaded the JDT ls server, which made me realise that Nixpkgs
version was too old, and thats why it did not provide autocompletions for Spring
Boot annotations etc
This makes things declarative and easier to find bugs and dependency graph.
There are quite a few things not working as expected, but we'll see about that
in due time.
Now that I know what is going on, here's how to fix it for next time:
- Remove all old pdf package repos related to this
- doom purge
- doom sync -u
This is to be done after nixos-switch is successful.
I've recognised the need to have familiar and lightweight Java development
environment, which appears as simple editor, and unrecognizable to those who
know Eclipse/Intellij but still comes to aid in lightweight problem solving,
helping fix syntax and linting issues, in case the person with me (*cough*)
finds it 'difficult' to understand the program (facepalm).
- Refactor org config and set most variables before loading org, as is
recommended, rather than after
- autoload org on mu4e-org-store-and-capture command
- Keep the hook removal after loading, as it makes kinda sense
Windows updated and never to disappoint, broke HiDPI config for WSL.
For now, after much experimentation, I've settled on this half-assed fix where
fonts are legible, but everything else is tiny. It'll have to do for time being.
Windows updated and never to fail, it screwed up DPI for WSLg, setting it back
to tiny fonts.
So, this makes things slightly better, by making most text legible.
It still means some things are tiny, but such is the life in Microsoft World™
This is the modeline from NANO emacs, and by default it is configured to be
*very* minimal.
It is an experiment, although am not quite sure how to carry it forward.
Will see how it goes. It definitely is less crowded than doom-modeline, and
definitely easier to make look short, but we'll see, I guess.
- emacsql
- emacsql-sqlite
- emacsql-sqlite-builtin
- tree-sitter-langs
These all need external native component, so kinda makes sense to keep it like
this.
It is an experiment, particularly to see how org-roam accepts emacsql to be
built in, I'd prefer for it to not incessantly compile so often.
Tree-sitter-langs is a curious one. Without it being preferred built-in, it does
not seem to work. But, the highlights are almost always worse than otherwise,
and kinda useless. It is going to be interesting to see how that one plays out.
This is because setting them before meant some variables are overridden. e.g.
sending emails via msmtp does not work, because sendmail-function is overridden.
- Make Gnus require mu4e by loading it before gnus via use-package
- Set all relevant stock variables before mu4e is loaded
- Add rudimentary contact filtering to mu4e
- Do full search for mu4e
- Consolidate all mu4e variables in single setq expression
- consolidate all gnus variables in single setq expression
- generally make better use of use-package keywords
Default search limit is of 500 items, which was pretty fair before latest
update. With newer versions, search query is insanely fast and the results
appear before noticeable delay. My mailbox is also not too big, and it is
possible to keep doing full search with my latest hardware.
mu4e has limit of some 2000 contacts. So it makes sense to not save the BS
contacts. This function was inspired by:
https://www.djcbsoftware.nl/code/mu/mu4e/Contact-functions.html
If proven useful, it can be extended to add more matches, e.g. donotreply,
linkedin, other internet pests etc
- when switching to mu4e-headers-mode and mu4e-main-mode
- After executing marks, usually done for deleting/trashing mails
- dedicated keybind (originally for lazy index update)
This is done because I noticed index not updating after deleting/trashing emails
and needed to manually execute 'mu index'.
Doom is having issues with latest Emacs 29 so my hackneyed fix is to just
include any package remotely having issues with the emacs-pgtk-with-pkgs
derivation.
I'm not fully sure if it works, but it don't cost, so might as well..
Might also provide future opportunity to bundle it all with NixOS build,
especially since upstream NixOS now compiles and provides binaries for all
ELPA/MELPA packages via cache.nixos.org.
By default elixirLS looks for .git in root and checks for mix file present in
it.
For projects that are not under vc/git, such as all the ones during my current
learning phase, this becomes tedious and makes the language server half useless.
This little snippet found on github:
https://github.com/elixir-lsp/elixir-ls/issues/364#issuecomment-690987776
..makes it possible for elixirLS to work with projects even without being
tracked under git.
Including ox-publish, ox-RSS and bhankas-blog.el
I haven't worked on blog since May, not sure when I'll work on it, so might as
well stop loading them.
Also stops the white flash of Emacs window when starting in WSL
Upstream updates to modulep! macro made autoload buggy and not recognise eglot.
So instead of eglot-ensure, it now tries to call lsp-deferred function, which
doesn't exist because lsp-mode is not installed.
Instead of staying on older doom version, just define lsp-deferred to call
eglot-ensure, and problem goes away. Remove once upstream issue is closed:
https://github.com/doomemacs/doomemacs/issues/6771
After bit of investigation across doom and package wiki and source code, bit
more googling to see why the flags were missing, turns out the font package was
missing from NixOS.
all-the-icons package in emacs closure is not strictly necessary, as doom is
expected to download it automatically, but I'll probably always have it, so its
a safe bet to keep both in sync.
Not yet sure how I'll use it, but we'll see.
Doom's module is also intended to make multiple cursors more integrated with
Evil-mode which I have left many moons ago, so further scrutiny needed.
Now logs practically every change in TODO status with a note except moving to
TODO (rather than WAITING, CANCELLED or DONE, which are all logged with
timestamp+note).
Also logs all reschedule, redeadline and repeats with timestamp as well as note.
This way the org file themselves can become transactional and log all state
changes to become a log themselves. They can then be used to produce graphs or
whatever.
IIRC originally I chose to have file level keywords for better visibility as
well as to have ability to change them top level in future and still have
old individual files be able to transition between TODO states.
At this point, my TODO keywords have not changed for a while, they seem to be
doing the job well enough, and I have gotten much better used to the states so
far.
After getting used to this setup, I am also more reluctant to introduce more
custom TODO states for individual projects as this one works for me, but if the
need arises in future, I can simply add them back in new templates.
My mail compose is set to use mu4e (which uses Gnus mail compose facilities with
its own flavors on top). If I open Gnus and try replying to email before having
opened mu4e in that session, mu4e special sauce in compose is missing and mail
sending fails since that is also handled by mu4e along with sending account.
So, the choice was to always load mu4e.
This has the effect of increasing Emacs launch times, but I think that is
alright. So far, even with increasing number of packages being eagerly loaded,
my Emacs launches under 5 seconds consistently. But, this might be good time to
think about managing dependencies fully lazily with use-package effectively.
This is an experiment, because Gmail does not allow deletion, but only trashing.
Doom's mu4e module has some implementation regarding that.
Anyway, we'll see how this one goes
The bug was happening because simply setting org-agenda-files to
global-org-directory does not scan org for org files recursively. Which means
daily files were not part of agenda.
My patchfix for that was to recursively list all org files in
global-org-directory recursively. Problem with that is it only scans all files
once, during Emacs startup. If any new files are created after startup, e.g. new
daily file is started, it is not part of org-agenda-files in that Emacs session,
and agenda does not include that until
- Emacs is restarted, triggering a rescan OR
- Manual restart is triggered
I wrote a function to do that in bhankas.el, but that was still clukny and
hacky, required manual operation and there was no nice solution.
But, I just tried out simply listing directories, had to debug a bit, turns out
the ffap function I was using to recursively list subdirectories was not loaded
on startup. Once I require'd it, org-agenda worked and started showing new files
immediately!
It is nice to not have to worry about this problem any more :)
The bug that caused doom+modus to inflate mode-line height by 2 pixels appears
to be resolved, so there is no longer need to reduce the font size and custom
padding parameter.
If in future this bug reappears, this commit can be safely reverted to get
original appearance back.
The LSP setup was bit more involved than expected, but it works.
- Create environment variable with ls package path.
- Do this globally because Fish is not yet managed by home-manager
- Use the variable to get package path in Emacs (configured in Doom Emacs
config)
Currently the Elixir stuff is installed globally but this can work as far as I
can see. I might have to synchronise between project and system flake
occasionally, but I think it will be manageable for a while.
Since I'm playing around with Elixir and Phoenix LiveView framework, and it
being less IDE supported, dynamically typed language, I'm gonna make use of
Emacs to develop.
Doom has built-in module for Elixir, with LSP support (no tree-sitter, sadly),
and enabling that was easy.
Getting LSP to work was bit more involved.
- add elixir_lsp to global packages in NixOS
- create environment variable to get the elixir_lsp package path. This had to be
done globally because my shell is not managed by home-manager yet
- remove default language_server.sh path from eglot server list for elixir. This
is kinda weird, because the elixir ls does not have a simple binary, but instead
uses a shell script in its dir to start up. As expected that was more involved
setup with NixOS
- Add correct path to language_server.sh path by using the environment variable
defined in NixOS config.
After this, eglot finds and connects to elixir LS correctly. There are
supposedly some issues with mix file, but that can wait for now.
It looks a lot better on HiDPI display and larger font size.
So, I will probably keep it for time being.
Also remove all other fonts. I had picked them from tecosaur's config, but
didn't really see any use of them, so might as well remove the extra fluff.
Gonna try out Phoenix LiveView + elixir and see how the concurrency +
metaprogramming plays out there.
Java's green threads will take probably 5+ years to actually propagate to
SpringBoot + other programmers, so right now, concurrent + compiled + fast +
decently supported ecosystems are limited to Go and BEAM.
From them, Go never actually quite caught my fancy because the language is
hamstrung with basicness and demands extensive boilerplate. It has some
benefits associated, but right now I'd rather experiment with a more developing
ecosystem. Elixir+phoenix also allows getting away from Javascript for the most
part, so maybe that will turn out beneficial as well. We'll see.