For any files under my WIKIROOT directory I am sure that they are
textual (if they fall into the wrapping.nvim allowlist).
So we do not need to undertake the 'nontextual' file heuristic that uses
the capabilities of the language server connected. Especially since our
ZK lsp, or markdown lsp would always return the capability.
Unfortunately wrapping.nvim does not currently have the ability to
provide your own 'nontextual' heuristic, so I instead use a fork which
does and provide the correct function in the options.
By default we wrap the contents.
This will slightly worsen some coding previews, but greatly improve the
default preview for text files.
We will see if it makes sense to keep over time but this makes more
sense to me right now -- especially with zk.nvim using fzf-lua as
preview provider.
We found the correct option and it does not instant-select single result
search anymore.
So we can remove the FIXME since it is indeed fixed.
WIP: ZK workflow improvements
Correctly append md_like and org_like into prose filetypes.
And correctly load render_markdown for all md_like filetypes.
NOTE: _Still_ does not work to render for djot on my end. Is it because
of different TS queries? I am not sure.
Also given new mapping. Hit `<c-t>` instead of `<c-x>`. `<c-x>` (in
insert mode) instead now brings up the path completion which was
previously on the other mapping.
On any line in a markdown-like file (i.e. markdown, quarto, djot, etc.),
we can hit `<c-t>` in normal mode or insert mode to toggle the current
line having a checkbox or not. It takes care to leave the current item a
list item like it was if it already was filled with content.
It does _not_ remove the list item even if it is empty, this may be an
improvement for the future (i.e., empty line -> we hit <c-t> -> line
turns into `- [ ] ` -> we hit <c-t> -> line stays `- `).
But care should be taken to not remove a list item if we don't intend
to, e.g. we could have toggled part of a list beforehand and don't want
to remove the list on each toggle. That's why it is more conservative
for now and I think it should work well enough (the case is likely to be
rare in my mind).
Also, while it does pick up the extended checkbox symbols ([o], [~], [-]),
those are currently hardcoded into the query.
In my mind it should pick those up dynamically from another plugin
instead of hardcoding here, e.g. render-markdown which also defines the
symbols?
Lastly, we could extend it to use treesitter queries instead / on top if
TS is found which would make it more robust than regex matching. But for
an hour of hacking it works quite well.
Shamelessly stolen from http://www.lazyvim.org/plugins/coding#miniai,
allows us to select in/around:
[c]lass, [f]unction, [d]igits, MultiCas[e] words, [g]lobal buffer,
[u]sage of functions (function calls) or the last part of a function
[Usage] and the current code bl[o]ck (loop, conditional or block).
Super useful!
Could be optionally set for 'blink' but since blink.cmp also displays
lsp results this is more general (and, currently, the recommended way).
Suggests task states if doing a single '-' dash at an appropriate place.
In 'next' view (my default) we list all annotations as normal with their
full text.
However, in 'list' view, we only show how many annotations are on a task
(if any) and do not display their contents. This turns it into actually
more of a list if there are many annotated tasks.
Following this blogpost:
https://eshapard.github.io/code/a-separate-taskwarrior-configuration-for-ideas.html
I think it is a really good idea to try this out.
At first I was collecting ideas in my regular taskwarrior repository --
this was no good as every task list was flooded by somedays and maybes
which would never leave. But I still wanted to have a nice repository to
collect all my ideas in.
So, the second strategy was to have one big (markdown) file which would
simply collect all my ideas. But now I was doubling and tripling them up
because the list was so long, and it was more of a chore to find where
to put everything than just a quick 'idea add'.
This may be the best of both worlds: making use of the nice interface to
a task database using the full strength of taskwarrior querying, without
cluttering up my main task repository.
The workflow is exactly as with regular taskwarrior, only the executable
is not called `task` (or `t` in my case) but `idea`. So you e.g. add an
idea with `idea add`, or query all diy ideas with `idea +diy`.
Just like regular taskwarrior.
Since I am exclusively using `topen`
(https://git.martyoeh.me/Marty/topen) for my task notes currently, this
commit gets rid of any left-over config files setting up `taskopen`.
Starts to simplify the taskwarrior setup a tiny bit.
This commit changes the way I display my jj logs a little. We
distinguish between 3 styles now
- the 'stack()': short and to the point, only ancestor commits from the
last non-mutable one onwards
- the 'recent()': the previously default view over ancestor commits or
any other head nodes (i.e. any branches) that are from me,
with a few commits leading up to them visible.
- the 'all()': the traditional 'show everything' summation for finding
very specific commits or getting a macro-scale overview of the history
Basically, only the 'stack()' view was added - but it is now the new
default for the default command and the previous 'default' has been
renamed to 'recent()'.
This is mirrored in the shell aliases: all the `jl`, `jlo`, `jloo`
aliases use the 'recents()' view. The capital versions (`JL` and the
like) are not affected as as they keep showing the 'all()' view.
Importantly, the `j` base command uses the 'stack()' view, however.
Lastly, we extract the aliases to find `WIP:` commits and `PRIVATE:`
commits into actual jj revset aliases and call them from our shell
aliases. The functionality does not change, though we now have an
additional alias for finding specifically the latter commits with `jlfp`
('jj log find private').
Using lazy-events.nvim we can create custom events (such as the LazyVim
equivalent LazyFile event) based on other events (i.e. a grouping), on
globbing files in the current dir, or on arbitrary custom logic.
For now, any plugins which require files to be present to work are
loaded with the 'LazyFile' event.
Any plugins which need to be loaded when opening a directory with vim
are loaded with the 'StartWithDir' event (essentially only neo-tree for
now). Similarly mini.starter is loaded on the `StartScreen` event.
Any plugin which only makes sense to run in a `.git` dir (gitsigns etc)
will only run on the `LazyProject:git` event.
Automatically opens dap-view when in debugging session (and closes when
done), sets some breakpoint jump logic and makes the gutter symbols
nicer.
Adds keybinds for most of the dap operations with
`<localleader>d<something>` where something is the operation (i.e. `c`
for continue, `b` for breakpoint and so on).
For now there is no strict reason to have it disabled, even if I don't
use it much. At the same time I can always re-disable it if I need the
bracketed movement for something more important later down the line.
In preparation for adding debugging we change the bracket movement
between diagnostics from `[d`/`]d` to `[e`/`]e` instead.
This will be a big switch in muscle memory for me and I hope I can adapt
to it pretty quickly, but at least mnemonically it still makes sense
since we jump between [E]rrors (or warnings but good enough).
mini.bracketed never received its configuration which is the reason I
had some issues in the past. It was simply wrapped in one too many
layers of tables. Now works as intended.