Compare commits

..

25 commits

Author SHA1 Message Date
065488e57d
nvim: Remove debug printing of activated python venv
Removed notification on activating a python venv.
It should just work, transparent to the user and we do
not need a big ol' notification each time we enter
a file.
2023-10-02 19:21:29 +02:00
bfb62e6783
nvim: Add markdown code evaluation mappings
Can edit (`<ll>ce`), jump-to (`]c`, `[c`), insert (`<ll>co`,
`<ll>cO`) and run (`<ll>cc`) code cells in markdown files.

They will not be evaluated as part of an overall repl but
only stand-alone!
2023-10-02 19:20:44 +02:00
8b603b8c66
nvim: Improve lazy-loading of select plugins
Aerial (on command), test-runners (on python only) and other plugins
are now only loaded when actually required.
2023-10-02 19:18:29 +02:00
643deaebec
papis: Add ability to show tag counts to papis-tags
The `papis tags` command is extended with the functionality to not
just display all tags used in current query, sorted alphabetically,
but also to display how often they appear.

Use `papis tags -c` to show a space-separated count of how often
each tag is used next to the tag name, in descending order.
2023-10-02 19:16:23 +02:00
c4809c78f7
vidl: Use new default video location 2023-10-02 19:14:50 +02:00
587a46ccb7
qutebrowser: Disable canvas fingerprinting
Do not allow html5 canvas reading in qutebrowser. This shuts off one of the main
avenues of browser fingerprinting (aside from cookies) still currently
undertaken. It will possibly stop some obscure streaming sites from working but
I do not care, especially at the cost of fingerprinting information.
2023-10-02 19:14:25 +02:00
48229fc742
qutebrowser: Set tab display length to 2 seconds
When not showing tabs (only displaying them on actually
switchting between tabs), so far the duration that the
tabs would be displayed was just 800ms, way too short
to actually provide legible info.

This commit changes it to 2000ms, which may still be
too short but is at least more digestible.
2023-10-02 19:12:56 +02:00
093bc811d5
multimedia: Add simple imv configuration
Added simple configuration for the imv image viewer which is
wayland-compatible. Nothing too fancy but some simple
vim-like mappings are set, as well as some styling applied.
2023-10-02 19:11:20 +02:00
0fcac78b1f
git: Add date-enabled short log aliases
In addition to the existing `glg` and `glga` aliases for showing
one-line git logs for current or all branches, this commit adds
`glgd` and `glgad` for showing one-line git logs for current or
all branches *with date information*.

The date info comes from authoring date not committing date.
2023-10-02 19:10:27 +02:00
ec74d0ddff
xdg: Change default video directory location
Changed from ~/videos to ~/media/videos to declutter
home somewhat.
2023-10-02 19:08:40 +02:00
bad45b937d
river: Do not always restart kanshi with river
Kanshi used to be restarted every time river would be reloaded.
This is not desired however, as restarting river would also
kill the kanshi daemon, and subsequently reload it, reseting
any custom kanshi output layouts or options set.

With this commit kanshi only gets started if it is not already
running through river (i.e. on first boot most of the time).
2023-10-02 19:07:58 +02:00
e98d527f5d
river: Add gap toggling key bind
Use F10 to enable gaps (default) or Shift+F10 to disable gaps.
TODO Would love to make it a toggle on pressing F10 alone, but
I am not sure we can get the current gap width from the
layout in any way.
2023-10-02 19:05:58 +02:00
6bca05f212
river: Make volume and brightness keys repeatable
Will rapidly increase/decrease brightness and volume
when holding down the corresponding keys.
2023-10-02 19:01:31 +02:00
102cdbca1c
writing: Replace zathura with sioyek
Replaced or extended all default references to zathura with
sioyek so it will automatically take on any tasks meant
for pdf reading. With the current configuration, hardly a
change should be noticed.
2023-10-02 14:08:04 +02:00
af410c0b77
writing: Add sioyek configuration 2023-10-02 13:55:46 +02:00
334f3032e8
terminal: Exchange fasd for zoxide
fasd is unmaintained and slower than zoxide. The transferral
was painless. I imported my old database and can continue as
before. It does not care about files but that is completely
fine for me. Same `z` invocation as before. Has the
'interactive' mode on `zi` which is also completely fine.
2023-09-28 14:41:33 +02:00
bf2e74265c
nvim: Auto format prose soft with word-linebreaks
Automatically set formatting mode to soft for markdown, text and asciidoc files.
Also automatically format on startup (no lazy-loading), and thus have
nicely word-ending linebreaks (a word will not just be cut off wherever the
line is over but will be fully moved to the next line instead).
2023-09-25 19:54:38 +02:00
490232d18a
nvim: Update plugins 2023-09-25 19:44:11 +02:00
dfb9d7ff01
timewarrior: Add hash and plus to taskwarrior tags
Add a hash sign in front of 'project' tags received from
taskwarrior (i.e. where it is `project:something` it will
end up as #something in timewarrior.

Similarly, add a plus sign in front of tags: `+mytag`.
Only descriptions will be left as-is in translating from
taskwarrior to timewarrior.

This should make finding tags and projects specifically
much easier in timewarrior (e.g. for counting up the total
time spent on a single project).
2023-09-25 19:43:58 +02:00
23793795d6
nvim: Add coverage support for python testing
Use `,tp` to load a coverage report and show it in the gutter.
Use `,tP` to toggle it off and on. Use `,ts` to show a summary
instead.
2023-09-25 19:41:27 +02:00
497b19fcbe
nvim: Add util function to grab plugin conditionally 2023-09-25 19:39:51 +02:00
41934d3000
nvim: Attach ruff client to active python environment 2023-09-25 19:38:57 +02:00
8a5381a4aa
nvim: Add test setup for python to ide
Added neotest with some mappings to run tests and view
outputs, as well as neotest-python for now to make it
work under python.

Added registering with which-key if it exists.
2023-09-23 08:37:29 +02:00
e016b0a056
nvim: Remap lsp go to next/previous error
Mapped to `[D` / `]D`, reflecting the capitalization of going to the
next general diagnostic (`[d`/`]d`).
Now it is similar to spelling mistakes and spelling errors
(`]s[s`/`]S[S` respectively).
2023-09-23 07:43:49 +02:00
dc9f9373fe
nvim: Remove obsolete mappings
Removed easyread and nabla toggles since the plugins are removed.
2023-09-23 07:41:37 +02:00
35 changed files with 460 additions and 123 deletions

View file

@ -69,7 +69,6 @@ exa ls replacement R
exercism-bin Command line client for exercism.io A exercism-bin Command line client for exercism.io A
exfat-utils Utilities for exFAT file system R exfat-utils Utilities for exFAT file system R
f3 Simple tool that tests flash cards capacity and performance to see if they live up to claimed specifications A f3 Simple tool that tests flash cards capacity and performance to see if they live up to claimed specifications A
fasd Command-line productivity booster, offers quick access to files and directories R
fd Simple, fast and user-friendly alternative to find R fd Simple, fast and user-friendly alternative to find R
ffmpegthumbnailer Lightweight video thumbnailer that can be used by file managers R ffmpegthumbnailer Lightweight video thumbnailer that can be used by file managers R
firefox Standalone web browser from mozilla.org R firefox Standalone web browser from mozilla.org R
@ -275,6 +274,7 @@ screen Full-screen window manager that multiplexes a physical terminal R
sfz A simple static file server A sfz A simple static file server A
shellcheck-bin Shell script analysis tool (binary release, static) A shellcheck-bin Shell script analysis tool (binary release, static) A
shfmt Format shell programs R shfmt Format shell programs R
sioyek PDF viewer for research papers and technical books. A
slurp Select a region in a Wayland compositor R slurp Select a region in a Wayland compositor R
smartmontools Control and monitor S.M.A.R.T. enabled ATA and SCSI Hard Drives R smartmontools Control and monitor S.M.A.R.T. enabled ATA and SCSI Hard Drives R
snap-pac Pacman hooks that use snapper to create pre/post btrfs snapshots like openSUSE's YaST R snap-pac Pacman hooks that use snapper to create pre/post btrfs snapshots like openSUSE's YaST R
@ -357,6 +357,7 @@ zathura-djvu DjVu support for Zathura R
zathura-pdf-mupdf PDF support for Zathura (MuPDF backend) (Supports PDF, ePub, and OpenXPS) R zathura-pdf-mupdf PDF support for Zathura (MuPDF backend) (Supports PDF, ePub, and OpenXPS) R
zk A command-line tool helping you to maintain a Zettelkasten or personal wiki R zk A command-line tool helping you to maintain a Zettelkasten or personal wiki R
zotero-bin Zotero Standalone. Is a free, easy-to-use tool to help you collect, organize, cite, and share your research sources. A zotero-bin Zotero Standalone. Is a free, easy-to-use tool to help you collect, organize, cite, and share your research sources. A
zoxide A smarter cd command for your terminal R
zq Tooling for super-structured data A zq Tooling for super-structured data A
zsh-autosuggestions Fish-like autosuggestions for zsh R zsh-autosuggestions Fish-like autosuggestions for zsh R
zsh-fast-syntax-highlighting Optimized and extended zsh-syntax-highlighting A zsh-fast-syntax-highlighting Optimized and extended zsh-syntax-highlighting A

Can't render this file because it has a wrong number of fields in line 29.

View file

@ -1,7 +1,17 @@
Name Description Source Target Name Description Source Target
adbfs-rootless-git fuse filesystem over adb tool for android devices, no device root required A adbfs-rootless-git fuse filesystem over adb tool for android devices, no device root required A
eslint An AST-based pattern checker for JavaScript R arch-install-scripts Scripts to aid in installing Arch Linux R
blueberry Bluetooth configuration tool R
dotter-rs-bin A dotfile manager and templater written in Rust A
eza A modern replacement for ls (community fork of exa) R
feishin-appimage A modern self-hosted music player. A
git-delta Syntax-highlighting pager for git and diff output R
khal CLI calendar application built around CalDAV R
m4b-tool-bin A command line utility to merge, split and chapterize audiobook files such as mp3, ogg, flac, m4a or m4b A m4b-tool-bin A command line utility to merge, split and chapterize audiobook files such as mp3, ogg, flac, m4a or m4b A
qutebrowser-qt6-git A keyboard-driven, vim-like browser based on PyQt5 (Qt 6 branch) A nodejs-markmap-cli Create markmaps (mindmaps from markdown) from CLI A
pv A terminal-based tool for monitoring the progress of data through a pipeline R
qpwgraph PipeWire Graph Qt GUI Interface R
texlive-latexextra TeX Live - LaTeX additional packages R texlive-latexextra TeX Live - LaTeX additional packages R
time Utility for monitoring a program's use of system resources R toilet Free replacement for the FIGlet utility R
vifm A file manager with curses interface, which provides Vi[m]-like environment R
woeusb-ng Simple tool that enable you to create your own usb stick with Windows installer. A

1 Name Description Source Target
2 adbfs-rootless-git fuse filesystem over adb tool for android devices, no device root required A
3 eslint arch-install-scripts An AST-based pattern checker for JavaScript Scripts to aid in installing Arch Linux R
4 blueberry Bluetooth configuration tool R
5 dotter-rs-bin A dotfile manager and templater written in Rust A
6 eza A modern replacement for ls (community fork of exa) R
7 feishin-appimage A modern self-hosted music player. A
8 git-delta Syntax-highlighting pager for git and diff output R
9 khal CLI calendar application built around CalDAV R
10 m4b-tool-bin A command line utility to merge, split and chapterize audiobook files such as mp3, ogg, flac, m4a or m4b A
11 qutebrowser-qt6-git nodejs-markmap-cli A keyboard-driven, vim-like browser based on PyQt5 (Qt 6 branch) Create markmaps (mindmaps from markdown) from CLI A
12 pv A terminal-based tool for monitoring the progress of data through a pipeline R
13 qpwgraph PipeWire Graph Qt GUI Interface R
14 texlive-latexextra TeX Live - LaTeX additional packages R
15 time toilet Utility for monitoring a program's use of system resources Free replacement for the FIGlet utility R
16 vifm A file manager with curses interface, which provides Vi[m]-like environment R
17 woeusb-ng Simple tool that enable you to create your own usb stick with Windows installer. A

View file

@ -82,3 +82,11 @@ rewrite = false
start = "# Start flavours" start = "# Start flavours"
end = "# End flavours" end = "# End flavours"
hook = "killall mako" hook = "killall mako"
[[items]]
# SIOYEK does not support includes afaik
template = "sioyek"
file = "~/.config/sioyek/prefs_user.config"
rewrite = false
start = "# START FLAVOURS"
end = "# END FLAVOURS"

View file

@ -0,0 +1,20 @@
# base16-sioyek (https://github.com/loiccoyle/base16-sioyek)
# by Loic Coyle
# {{scheme-name}} scheme by{{scheme-author}}
custom_background_color #{{base00-hex}}
custom_text_color #{{base06-hex}}
page_separator_color #{{base00-hex}}
search_highlight_color #{{base0A-hex}}
status_bar_color #{{base00-hex}}
status_bar_text_color #{{base06-hex}}
ui_text_color #{{base06-hex}}
ui_selected_text_color #{{base06-hex}}
ui_background_color #{{base01-hex}}
ui_selected_background_color #{{base03-hex}}
background_color #{{base00-hex}}
visual_mark_color {{base03-dec-r}} {{base03-dec-g}} {{base03-dec-b}} 0.2
text_highlight_color #{{base03-hex}}
link_highlight_color #{{base0D-hex}}
synctex_highlight_color #{{base08-hex}}

View file

@ -124,6 +124,9 @@ riverctl map normal $mod F toggle-fullscreen
# Make all connected outputs show the desktop and no windows at all # Make all connected outputs show the desktop and no windows at all
riverctl map normal $mod+Shift M spawn 'for i in $(wlopm | wc -l); do riverctl set-focused-tags $((1 << 10)); riverctl focus-output next; done; riverctl set-focused-tags $((1 << 10)); riverctl focus-output next' riverctl map normal $mod+Shift M spawn 'for i in $(wlopm | wc -l); do riverctl set-focused-tags $((1 << 10)); riverctl focus-output next; done; riverctl set-focused-tags $((1 << 10)); riverctl focus-output next'
riverctl map normal $mod+Shift F10 spawn 'riverctl send-layout-cmd rivercarro "gaps 0"'
riverctl map normal $mod F10 spawn 'riverctl send-layout-cmd rivercarro "gaps 6"'
# toggle float # toggle float
riverctl map normal $mod+Shift v toggle-float riverctl map normal $mod+Shift v toggle-float
# Mod + Left Mouse Button to move views # Mod + Left Mouse Button to move views
@ -191,8 +194,8 @@ for mode in normal locked; do
# Eject the optical drive # Eject the optical drive
riverctl map $mode None XF86Eject spawn 'eject -T' riverctl map $mode None XF86Eject spawn 'eject -T'
riverctl map $mode None XF86AudioRaiseVolume spawn 'pactl set-sink-volume @DEFAULT_SINK@ +5%' riverctl map -repeat $mode None XF86AudioRaiseVolume spawn 'pactl set-sink-volume @DEFAULT_SINK@ +5%'
riverctl map $mode None XF86AudioLowerVolume spawn 'pactl set-sink-volume @DEFAULT_SINK@ -5%' riverctl map -repeat $mode None XF86AudioLowerVolume spawn 'pactl set-sink-volume @DEFAULT_SINK@ -5%'
riverctl map $mode None XF86AudioMute spawn 'pactl set-sink-mute @DEFAULT_SINK@ toggle' riverctl map $mode None XF86AudioMute spawn 'pactl set-sink-mute @DEFAULT_SINK@ toggle'
# Control MPRIS aware media players with playerctl (https://github.com/altdesktop/playerctl) # Control MPRIS aware media players with playerctl (https://github.com/altdesktop/playerctl)
@ -202,8 +205,8 @@ for mode in normal locked; do
riverctl map $mode None XF86AudioNext spawn 'playerctl next' riverctl map $mode None XF86AudioNext spawn 'playerctl next'
# You can control screen backlight brighness with light (https://github.com/haikarainen/light); but we prefer brightnessctl # You can control screen backlight brighness with light (https://github.com/haikarainen/light); but we prefer brightnessctl
riverctl map $mode None XF86MonBrightnessUp spawn 'brightnessctl set 10%+' riverctl map -repeat $mode None XF86MonBrightnessUp spawn 'brightnessctl set 10%+'
riverctl map $mode None XF86MonBrightnessDown spawn 'brightnessctl set 10%-' riverctl map -repeat $mode None XF86MonBrightnessDown spawn 'brightnessctl set 10%-'
done done
# The scratchpad will live on an unused tag. Which tags are used depends on your # The scratchpad will live on an unused tag. Which tags are used depends on your
@ -239,6 +242,9 @@ done
setxkbmap -option "compose:menu" setxkbmap -option "compose:menu"
# start dynamic display configuration
[ "$(pidof kanshi)" -eq 0 ] || riverctl spawn kanshi
# set a nice wallpaper # set a nice wallpaper
if exist swww; then if exist swww; then
riverctl spawn "swww init" riverctl spawn "swww init"
@ -255,10 +261,6 @@ fi
killall waybar killall waybar
riverctl spawn waybar riverctl spawn waybar
# start dynamic display configuration
killall kanshi
riverctl spawn kanshi
# start redshift-like sundown warming using current location or standard values # start redshift-like sundown warming using current location or standard values
killall wlsunset killall wlsunset
loc=$(curl ipinfo.io | grep -e '"loc": ' | sed -e 's/^.*"loc": "\(.*\)",$/\1/') loc=$(curl ipinfo.io | grep -e '"loc": ' | sed -e 's/^.*"loc": "\(.*\)",$/\1/')

View file

@ -12,4 +12,4 @@ XDG_MUSIC_DIR="$HOME/media/audio/music"
XDG_PICTURES_DIR="$HOME/pictures" XDG_PICTURES_DIR="$HOME/pictures"
XDG_PUBLICSHARE_DIR="$HOME/" XDG_PUBLICSHARE_DIR="$HOME/"
XDG_TEMPLATES_DIR="$HOME/" XDG_TEMPLATES_DIR="$HOME/"
XDG_VIDEOS_DIR="$HOME/" XDG_VIDEOS_DIR="$HOME/media/videos"

View file

@ -40,7 +40,9 @@ alias gi='git ignore'
alias gll='git last' alias gll='git last'
# show quick log overview # show quick log overview
alias glg='git log --oneline --decorate --graph' alias glg='git log --oneline --decorate --graph'
alias glgd="git log --graph --pretty=format:'%C(auto)%h%Creset %C(cyan)%ar%Creset%C(auto)%d%Creset %s'"
alias glga='git log --oneline --decorate --graph --remotes --all' alias glga='git log --oneline --decorate --graph --remotes --all'
alias glgad="git log --graph --remotes --all --pretty=format:'%C(auto)%h%Creset %C(cyan)%ar%Creset%C(auto)%d%Creset %s'"
# show detailed log overview # show detailed log overview
alias glog='git log --stat' alias glog='git log --stat'
# show detailed log overview with contents # show detailed log overview with contents

View file

@ -0,0 +1,20 @@
[options]
background = #080808
overlay = false
overlay_position_bottom = true
overlay_font = monospace:12
overlay_text_color = #c6c6c6
overlay_background_color = #1c1c1c
overlay_background_alpha = ff
[binds]
n = next
p = prev
o = overlay
<Shift+K> = zoom 5
<Shift+J> = zoom -5
<Shift+R> = rotate by 90
z = flip horizontal
<Shift+Z> = flip vertical
y = exec wl-copy "$imv_current_file"
Y = exec wl-copy < "$imv_current_file"

View file

@ -0,0 +1,25 @@
local map = vim.keymap.set
require('which-key').register({ ["<localleader>c" ] = { name = "+md-code"}})
require('which-key').register({ ["<localleader>e" ] = { name = "+criticmarkup"}})
-- edit code cells with full lsp access
map("n", "<localleader>ce", "<cmd>FeMaco<cr>", { silent = true, desc = "edit code block" })
-- execute code cells
map("n", "<localleader>cc", "<cmd>MdEval<cr>", { silent = true, desc = "evaluate code block" })
map("n", "<localleader>cx", "<cmd>MdEvalClean<cr>", { silent = true, desc = "clear code results" })
-- jump to beginning of previous/ next cell code
map("n", "]c", "/^```<cr>}:nohl<cr>", { desc = "next code cell" })
map("n", "[c", "?^```<cr>n}:nohl<cr>", { desc = "previous code cell" })
-- insert cell header above/below
map("n", "<localleader>co", "o```python<cr><cr>```<esc>k", { desc = "Insert quarto cell below" })
map("n", "<localleader>cO", "O```python<cr><cr>```<esc>k", { desc = "Insert quarto cell above" })
-- show nice md preview in browser (auto-syncs scrolling)
map("n", "<localleader>cp", "<Plug>MarkdownPreviewToggle", { desc = "show md preview" })
-- create mindmaps directly from markdown! requires external executable
if (vim.fn.executable("markmap")) then
map("n", "<localleader>cm", "<cmd>MarkmapOpen<cr>", { desc = "open md mindmap" })
map("n", "<localleader>cM", "<cmd>MarkmapWatch<cr>", { desc = "watch for md mindmap" })
end

View file

@ -4,7 +4,9 @@ local startsession = function(file, args)
local path = require("util").get_python_venv() local path = require("util").get_python_venv()
vim.g["python3_host_prog"] = path vim.g["python3_host_prog"] = path
if vim.fn.executable('jupyter-console') ~= 1 then return end if vim.fn.executable("jupyter-console") ~= 1 then
return
end
if args then if args then
file = args[0] file = args[0]

View file

@ -1,13 +1,14 @@
{ {
"Arduino.nvim": { "branch": "main", "commit": "1e986040861e77dd7107abfecc473c60ccd97d3f" }, "Arduino.nvim": { "branch": "main", "commit": "1e986040861e77dd7107abfecc473c60ccd97d3f" },
"BetterLua.vim": { "branch": "master", "commit": "d2d6c115575d09258a794a6f20ac60233eee59d5" }, "BetterLua.vim": { "branch": "master", "commit": "d2d6c115575d09258a794a6f20ac60233eee59d5" },
"FixCursorHold.nvim": { "branch": "master", "commit": "1900f89dc17c603eec29960f57c00bd9ae696495" },
"LuaSnip": { "branch": "master", "commit": "0b4950a237ce441a6a3a947d501622453f6860ea" }, "LuaSnip": { "branch": "master", "commit": "0b4950a237ce441a6a3a947d501622453f6860ea" },
"Navigator.nvim": { "branch": "master", "commit": "91d86506ac2a039504d5205d32a1d4bc7aa57072" }, "Navigator.nvim": { "branch": "master", "commit": "91d86506ac2a039504d5205d32a1d4bc7aa57072" },
"aerial.nvim": { "branch": "master", "commit": "fb1f08c9f90e8b0c04b2f2c5d95d06288a14c5b2" }, "aerial.nvim": { "branch": "master", "commit": "ae33427e1aa54bfdd164313716cdc10e7d7b927a" },
"bats.vim": { "branch": "master", "commit": "6a5d2ef22b0ede503d867770afd02ebb1f97b709" }, "bats.vim": { "branch": "master", "commit": "6a5d2ef22b0ede503d867770afd02ebb1f97b709" },
"cmp-beancount": { "branch": "main", "commit": "da154ea94d598e6649d6ad01efa0a8611eff460d" }, "cmp-beancount": { "branch": "main", "commit": "da154ea94d598e6649d6ad01efa0a8611eff460d" },
"cmp-buffer": { "branch": "main", "commit": "3022dbc9166796b644a841a02de8dd1cc1d311fa" }, "cmp-buffer": { "branch": "main", "commit": "3022dbc9166796b644a841a02de8dd1cc1d311fa" },
"cmp-calc": { "branch": "main", "commit": "50792f34a628ea6eb31d2c90e8df174671e4e7a0" }, "cmp-calc": { "branch": "main", "commit": "ce91d14d2e7a8b3f6ad86d85e34d41c1ae6268d9" },
"cmp-cmdline": { "branch": "main", "commit": "8ee981b4a91f536f52add291594e89fb6645e451" }, "cmp-cmdline": { "branch": "main", "commit": "8ee981b4a91f536f52add291594e89fb6645e451" },
"cmp-digraphs": { "branch": "master", "commit": "5efc1f0078d7c5f3ea1c8e3aad04da3fd6e081a9" }, "cmp-digraphs": { "branch": "master", "commit": "5efc1f0078d7c5f3ea1c8e3aad04da3fd6e081a9" },
"cmp-latex-symbols": { "branch": "main", "commit": "165fb66afdbd016eaa1570e41672c4c557b57124" }, "cmp-latex-symbols": { "branch": "main", "commit": "165fb66afdbd016eaa1570e41672c4c557b57124" },
@ -16,57 +17,64 @@
"cmp-nvim-lua": { "branch": "main", "commit": "f12408bdb54c39c23e67cab726264c10db33ada8" }, "cmp-nvim-lua": { "branch": "main", "commit": "f12408bdb54c39c23e67cab726264c10db33ada8" },
"cmp-pandoc-references": { "branch": "master", "commit": "2c808dff631a783ddd2c554c4c6033907589baf6" }, "cmp-pandoc-references": { "branch": "master", "commit": "2c808dff631a783ddd2c554c4c6033907589baf6" },
"cmp-path": { "branch": "main", "commit": "91ff86cd9c29299a64f968ebb45846c485725f23" }, "cmp-path": { "branch": "main", "commit": "91ff86cd9c29299a64f968ebb45846c485725f23" },
"cmp-rg": { "branch": "master", "commit": "1cad8eb315643d0df13c37401c03d7986f891011" }, "cmp-rg": { "branch": "master", "commit": "677a7874ee8f1afc648c2e7d63a97bc21a7663c5" },
"cmp-spell": { "branch": "master", "commit": "60584cb75e5e8bba5a0c9e4c3ab0791e0698bffa" }, "cmp-spell": { "branch": "master", "commit": "32a0867efa59b43edbb2db67b0871cfad90c9b66" },
"cmp-tmux": { "branch": "main", "commit": "984772716f66d8ee88535a6bf3f94c4b4e1301f5" }, "cmp-tmux": { "branch": "main", "commit": "97ec06b8030b8bf6d1fd83d49bdd16c98e04c845" },
"cmp-treesitter": { "branch": "master", "commit": "389eadd48c27aa6dc0e6b992644704f026802a2e" }, "cmp-treesitter": { "branch": "master", "commit": "389eadd48c27aa6dc0e6b992644704f026802a2e" },
"cmp_luasnip": { "branch": "master", "commit": "18095520391186d634a0045dacaa346291096566" }, "cmp_luasnip": { "branch": "master", "commit": "18095520391186d634a0045dacaa346291096566" },
"completion-vcard": { "branch": "master", "commit": "2220fd517a985ececed1adcf0e5be8f2815564c7" }, "completion-vcard": { "branch": "master", "commit": "2220fd517a985ececed1adcf0e5be8f2815564c7" },
"dial.nvim": { "branch": "master", "commit": "54b503f906bc9e5ab85288414840a1b86d40769f" }, "dial.nvim": { "branch": "master", "commit": "54b503f906bc9e5ab85288414840a1b86d40769f" },
"dressing.nvim": { "branch": "master", "commit": "c0b67f3e2950adc07b555d3e73e38275b4a585ce" }, "dressing.nvim": { "branch": "master", "commit": "59fe7ef1aeeed499b983614fcfff89206bf0d5ce" },
"fidget.nvim": { "branch": "main", "commit": "0ba1e16d07627532b6cae915cc992ecac249fb97" }, "fidget.nvim": { "branch": "main", "commit": "0ba1e16d07627532b6cae915cc992ecac249fb97" },
"friendly-snippets": { "branch": "main", "commit": "377d45475b49e37460a902d6d569d2093d4037d0" }, "friendly-snippets": { "branch": "main", "commit": "ebf6d6e83494cdd88a54a429340256f4dbb6a052" },
"fwatch.nvim": { "branch": "main", "commit": "a691f7349dc66285cd75a1a698dd28bca45f2bf8" }, "fwatch.nvim": { "branch": "main", "commit": "a691f7349dc66285cd75a1a698dd28bca45f2bf8" },
"git-conflict.nvim": { "branch": "main", "commit": "8d962d83cae924a314965f738ed1e05a4000d682" }, "git-conflict.nvim": { "branch": "main", "commit": "4e0191c9a0ae05d7fbdcdc7f15cd358f56d23bfb" },
"gitsigns.nvim": { "branch": "main", "commit": "bb808fc7376ed7bac0fbe8f47b83d4bf01738167" }, "gitsigns.nvim": { "branch": "main", "commit": "bb808fc7376ed7bac0fbe8f47b83d4bf01738167" },
"headlines.nvim": { "branch": "master", "commit": "74a083a3c32a08be24f7dfcc6f448ecf47857f46" }, "headlines.nvim": { "branch": "master", "commit": "74a083a3c32a08be24f7dfcc6f448ecf47857f46" },
"jupyter-kernel.nvim": { "branch": "main", "commit": "5b409598033884a3d819e2a3bcd1fe340bc8d783" }, "jupyter-kernel.nvim": { "branch": "main", "commit": "5b409598033884a3d819e2a3bcd1fe340bc8d783" },
"lazy.nvim": { "branch": "main", "commit": "3ad55ae678876516156cca2f361c51f7952a924b" }, "lazy.nvim": { "branch": "main", "commit": "3ad55ae678876516156cca2f361c51f7952a924b" },
"lightspeed.nvim": { "branch": "main", "commit": "299eefa6a9e2d881f1194587c573dad619fdb96f" }, "lightspeed.nvim": { "branch": "main", "commit": "299eefa6a9e2d881f1194587c573dad619fdb96f" },
"lsp-setup.nvim": { "branch": "main", "commit": "64542fb0da06414cdfaa0c5236b743679bb7ba7f" }, "lsp-setup.nvim": { "branch": "main", "commit": "7276e54faf4af909b6ea171975fd4179ebe65cec" },
"lualine.nvim": { "branch": "master", "commit": "45e27ca739c7be6c49e5496d14fcf45a303c3a63" }, "lualine.nvim": { "branch": "master", "commit": "45e27ca739c7be6c49e5496d14fcf45a303c3a63" },
"magma-nvim-goose": { "branch": "main", "commit": "9a626aab63361d027541d023707f82e28d7f872c" }, "magma-nvim-goose": { "branch": "main", "commit": "9a626aab63361d027541d023707f82e28d7f872c" },
"markdown-preview.nvim": { "branch": "master", "commit": "9becceee5740b7db6914da87358a183ad11b2049" }, "markdown-preview.nvim": { "branch": "master", "commit": "9becceee5740b7db6914da87358a183ad11b2049" },
"mason-lspconfig.nvim": { "branch": "main", "commit": "e86a4c84ff35240639643ffed56ee1c4d55f538e" }, "markmap.nvim": { "branch": "main", "commit": "3befc2a54c2448a16c30c1c7762aab263f22946a" },
"mason-lspconfig.nvim": { "branch": "main", "commit": "f014db32437aa61c86fc0ef1067cd2bc6a37205c" },
"mason-null-ls.nvim": { "branch": "main", "commit": "ae0c5fa57468ac65617f1bf821ba0c3a1e251f0c" }, "mason-null-ls.nvim": { "branch": "main", "commit": "ae0c5fa57468ac65617f1bf821ba0c3a1e251f0c" },
"mason.nvim": { "branch": "main", "commit": "74eac861b013786bf231b204b4ba9a7d380f4bd9" }, "mason.nvim": { "branch": "main", "commit": "d66c60e17dd6fd8165194b1d14d21f7eb2c1697a" },
"mini.nvim": { "branch": "main", "commit": "296ebbbd3e5ba5e43f5125efe18ad76fe3b632cc" }, "mdeval.nvim": { "branch": "master", "commit": "2654caf8ecaad702b50199d18e39cff23d81e0ba" },
"mini.nvim": { "branch": "main", "commit": "707dca4f4152c2d9c9b4c5e02635f78dfd33db50" },
"neotest": { "branch": "master", "commit": "6fd61fe665381939a6d70eb08ef1959a10af369e" },
"neotest-python": { "branch": "master", "commit": "81d2265efac717bb567bc15cc652ae10801286b3" },
"null-ls.nvim": { "branch": "main", "commit": "0010ea927ab7c09ef0ce9bf28c2b573fc302f5a7" }, "null-ls.nvim": { "branch": "main", "commit": "0010ea927ab7c09ef0ce9bf28c2b573fc302f5a7" },
"nvim-base16": { "branch": "master", "commit": "6247ca9aa9f34644dfa290a6df3f6feefb73eb97" }, "nvim-FeMaco.lua": { "branch": "main", "commit": "c4e9c71c9ca595772a360435bdf91bee3f9d32b1" },
"nvim-cmp": { "branch": "main", "commit": "51f1e11a89ec701221877532ee1a23557d291dd5" }, "nvim-base16": { "branch": "master", "commit": "96e308958625a84940d5e443475465abf99c7bd9" },
"nvim-cmp": { "branch": "main", "commit": "5dce1b778b85c717f6614e3f4da45e9f19f54435" },
"nvim-colorizer.lua": { "branch": "master", "commit": "dde3084106a70b9a79d48f426f6d6fec6fd203f7" }, "nvim-colorizer.lua": { "branch": "master", "commit": "dde3084106a70b9a79d48f426f6d6fec6fd203f7" },
"nvim-lspconfig": { "branch": "master", "commit": "0d29cad8de3b2c654315203fc1fe12fde722a18a" }, "nvim-coverage": { "branch": "main", "commit": "4634dfb00961a86948518c7e6f85737c24364308" },
"nvim-lspconfig": { "branch": "master", "commit": "bfdf2e91e7297a54bcc09d3e092a12bff69a1cf4" },
"nvim-notify": { "branch": "master", "commit": "ea9c8ce7a37f2238f934e087c255758659948e0f" }, "nvim-notify": { "branch": "master", "commit": "ea9c8ce7a37f2238f934e087c255758659948e0f" },
"nvim-surround": { "branch": "main", "commit": "0d6882635817a2677749a330127d12ac30a4f3c8" }, "nvim-surround": { "branch": "main", "commit": "0d6882635817a2677749a330127d12ac30a4f3c8" },
"nvim-toggleterm.lua": { "branch": "main", "commit": "b90a1381e9b5b8596f49070ee86c71db267ac868" }, "nvim-toggleterm.lua": { "branch": "main", "commit": "faee9d60428afc7857e0927fdc18daa6c409fa64" },
"nvim-tree.lua": { "branch": "master", "commit": "18c7a3119839adc4599d838726deae662859c8b2" }, "nvim-tree.lua": { "branch": "master", "commit": "ce3495bd4c9a7d8e8a64fac9cc3c252dac19a994" },
"nvim-treesitter": { "branch": "master", "commit": "63260da18bf273c76b8e2ea0db84eb901cab49ce" }, "nvim-treesitter": { "branch": "master", "commit": "63260da18bf273c76b8e2ea0db84eb901cab49ce" },
"nvim-treesitter-context": { "branch": "master", "commit": "d8fd71428e02190d8f75ff915b6cca9e3063992c" }, "nvim-treesitter-context": { "branch": "master", "commit": "6795de086ef713383e06b53faa534a597436159a" },
"nvim-treesitter-textsubjects": { "branch": "master", "commit": "df75fcec548014f158cda6498ac38c4622c221e1" }, "nvim-treesitter-textsubjects": { "branch": "master", "commit": "df75fcec548014f158cda6498ac38c4622c221e1" },
"nvim-ts-autotag": { "branch": "main", "commit": "6be1192965df35f94b8ea6d323354f7dc7a557e4" }, "nvim-ts-autotag": { "branch": "main", "commit": "6be1192965df35f94b8ea6d323354f7dc7a557e4" },
"nvim-ts-context-commentstring": { "branch": "main", "commit": "e9062e2dfb9854e6a927370f2d720de354c88524" }, "nvim-ts-context-commentstring": { "branch": "main", "commit": "95e9ba9de4289d221666b66fd930d157c7ca08c6" },
"nvim-ts-rainbow2": { "branch": "master", "commit": "b3120cd5ae9ca524af9cb602f41e12e301fa985f" }, "nvim-ts-rainbow2": { "branch": "master", "commit": "b3120cd5ae9ca524af9cb602f41e12e301fa985f" },
"nvim-web-devicons": { "branch": "master", "commit": "ab899311f8ae00a47eae8e0879506cead8eb1561" }, "nvim-web-devicons": { "branch": "master", "commit": "45d0237c427baba8cd05e0ab26d30e2ee58c2c82" },
"otter.nvim": { "branch": "main", "commit": "dda3359750a2f9c0d6ae073d967296f57fe99d8b" }, "otter.nvim": { "branch": "main", "commit": "2752dd199d73342f13a1bd599a99822505e2803f" },
"playground": { "branch": "master", "commit": "2b81a018a49f8e476341dfcb228b7b808baba68b" }, "playground": { "branch": "master", "commit": "ba48c6a62a280eefb7c85725b0915e021a1a0749" },
"plenary.nvim": { "branch": "master", "commit": "253d34830709d690f013daf2853a9d21ad7accab" }, "plenary.nvim": { "branch": "master", "commit": "253d34830709d690f013daf2853a9d21ad7accab" },
"popup.nvim": { "branch": "master", "commit": "b7404d35d5d3548a82149238289fa71f7f6de4ac" }, "popup.nvim": { "branch": "master", "commit": "b7404d35d5d3548a82149238289fa71f7f6de4ac" },
"quarto-nvim": { "branch": "main", "commit": "35f86035e7b3846dbf168267ffe0021c3d312259" }, "quarto-nvim": { "branch": "main", "commit": "b349b7e54f5f5543b6104bfbad0e7d09d4f7c564" },
"smartcolumn.nvim": { "branch": "main", "commit": "c2441d4490b7485844ac9ff2d44d882ff7536979" }, "smartcolumn.nvim": { "branch": "main", "commit": "d01b99355c7fab13233f48d0f28dc097e68a03f7" },
"telescope-fzf-native.nvim": { "branch": "main", "commit": "9bc8237565ded606e6c366a71c64c0af25cd7a50" }, "stickybuf.nvim": { "branch": "master", "commit": "e3db41f2c1bb2df3ee6ff964ee74fe991f6f9566" },
"telescope.nvim": { "branch": "master", "commit": "776b509f80dd49d8205b9b0d94485568236d1192" }, "telescope-fzf-native.nvim": { "branch": "main", "commit": "6c921ca12321edaa773e324ef64ea301a1d0da62" },
"telescope.nvim": { "branch": "master", "commit": "54930e1abfc94409e1bb9266e752ef8379008592" },
"twilight.nvim": { "branch": "main", "commit": "8bb7fa7b918baab1ca81b977102ddb54afa63512" }, "twilight.nvim": { "branch": "main", "commit": "8bb7fa7b918baab1ca81b977102ddb54afa63512" },
"undotree": { "branch": "main", "commit": "2685ce282702ab0b79c65916f352db2265b245dd" }, "undotree": { "branch": "main", "commit": "41f56b30cc774ad26c4945c7e10673453893e7ad" },
"vifm.vim": { "branch": "master", "commit": "a8130c37d144b51d84bee19f0532abcd3583383f" }, "vifm.vim": { "branch": "master", "commit": "a8130c37d144b51d84bee19f0532abcd3583383f" },
"vim-criticmarkup": { "branch": "master", "commit": "d15dc134eb177a170c79f6377f81eb02a9d20b02" }, "vim-criticmarkup": { "branch": "master", "commit": "d15dc134eb177a170c79f6377f81eb02a9d20b02" },
"vim-easy-align": { "branch": "master", "commit": "0db4ea6132110631ec678a99a82aa49a0686ae65" }, "vim-easy-align": { "branch": "master", "commit": "0db4ea6132110631ec678a99a82aa49a0686ae65" },

View file

@ -180,8 +180,6 @@ map("n", "<localleader>q", "gqap", { silent = true, desc = "Format current parag
map("x", "<localleader>q", "gq", { silent = true, desc = "Format {motion}" }) map("x", "<localleader>q", "gq", { silent = true, desc = "Format {motion}" })
map("n", "<localleader>Q", "vapJgqap", { silent = true, desc = "Unformat then format paragraph" }) map("n", "<localleader>Q", "vapJgqap", { silent = true, desc = "Unformat then format paragraph" })
map("n", "<localleader>mp", "<Plug>MarkdownPreviewToggle", { desc = "Toggle md preview" })
-- FORMAT code with -- FORMAT code with
-- PLUGIN: formatter.nvim -- PLUGIN: formatter.nvim
map("n", "<localleader>f", ":FormatLock<cr>") map("n", "<localleader>f", ":FormatLock<cr>")
@ -205,6 +203,7 @@ map("n", "<leader>ss", ":lua MiniStarter.open()<cr>", { desc = "show startpage"
-- PLUGIN: symbols-outline.nvim -- PLUGIN: symbols-outline.nvim
map("n", "<leader>so", "<cmd>AerialToggle<cr>", { silent = true, desc = "toggle symbol outline" }) map("n", "<leader>so", "<cmd>AerialToggle<cr>", { silent = true, desc = "toggle symbol outline" })
map("n", "<leader>sn", "<cmd>AerialNavToggle<cr>", { silent = true, desc = "toggle symbol navigator" })
-- PLUGIN: nvim-tree -- PLUGIN: nvim-tree
map("n", "<leader>se", "<cmd>NvimTreeToggle<cr>", { silent = true, desc = "toggle filetree" }) map("n", "<leader>se", "<cmd>NvimTreeToggle<cr>", { silent = true, desc = "toggle filetree" })
@ -255,13 +254,11 @@ map("v", "<localleader>nf", ":ZkMatch<cr>", { desc = "find note from selection"
-- PLUGIN: toggleterm.nvim -- PLUGIN: toggleterm.nvim
-- create a lazygit or python window, set up in toggleterm settings -- create a lazygit or python window, set up in toggleterm settings
-- TODO create ability to go into python environment when in poetry venv and/or euporie/jupyter notebook -- TODO create ability to go into python environment when in poetry venv and/or euporie/jupyter notebook
if is_available("nvim-toggleterm.lua") then prefix({ ["<localleader>t"] = { name = "+term" } })
map("n", "<leader>G", ":Lazygit<cr>") map("n", "<leader>tg", ":Lazygit<cr>")
map("n", "<leader>tg", ":Lazygit<cr>") map("n", "<leader>tG", ":Lazygit!<cr>")
map("n", "<leader>tG", ":Lazygit!<cr>") map("n", "<leader>tp", ":Pythonterm<cr>")
map("n", "<leader>tp", ":Pythonterm<cr>") map("n", "<leader>tP", ":Pythonterm!<cr>")
map("n", "<leader>tP", ":Pythonterm!<cr>")
end
prefix({ ["<localleader>s"] = { name = "+set" } }) prefix({ ["<localleader>s"] = { name = "+set" } })
-- PLUGIN: wrapping.nvim -- PLUGIN: wrapping.nvim
@ -271,16 +268,6 @@ map(
[[:lua require('wrapping').toggle_wrap_mode()<cr> ]], [[:lua require('wrapping').toggle_wrap_mode()<cr> ]],
{ silent = true, desc = "toggle wrap mode" } { silent = true, desc = "toggle wrap mode" }
) )
-- PLUGIN: easyread.nvim
map("n", "<localleader>ss", ":EasyreadToggle<cr>", { silent = true, desc = "toggle speedreading" })
-- PLUGIN: nabla.nvim
map("n", "<localleader>sv", '<cmd>lua require("nabla").popup()<cr>', { silent = true, desc = "latex formula popup" })
map(
"n",
"<localleader>sV",
'<cmd>lua require("nabla").toggle_virt({autogen = true, silent = true})<cr>',
{ silent = true, desc = "toggle formula notation" }
)
-- PLUGIN: nvim-colorizer -- PLUGIN: nvim-colorizer
map("n", "<localleader>sc", "<cmd>ColorizerToggle<cr>", { silent = true, desc = "toggle colorizer" }) map("n", "<localleader>sc", "<cmd>ColorizerToggle<cr>", { silent = true, desc = "toggle colorizer" })
map( map(
@ -291,10 +278,3 @@ map(
) )
map("n", "<leader>sa", "<cmd>FormatOnSave<cr>", { silent = true, desc = "toggle format on save" }) map("n", "<leader>sa", "<cmd>FormatOnSave<cr>", { silent = true, desc = "toggle format on save" })
-- PLUGIN: undotree
if is_available("undotree") then
map("n", "<leader>su", function()
require("undotree").toggle()
end, { silent = true, desc = "toggle undotree" })
end

View file

@ -48,13 +48,13 @@ local function on_attach(client, bufnr)
map("n", "]d", "<cmd>lua vim.diagnostic.goto_next()<cr>", { buffer = bufnr, desc = "Next diagnostic" }) map("n", "]d", "<cmd>lua vim.diagnostic.goto_next()<cr>", { buffer = bufnr, desc = "Next diagnostic" })
map( map(
"n", "n",
"[e", "[D",
"<cmd>lua vim.diagnostic.goto_prev({severity = vim.diagnostic.severity.ERROR})<cr>", "<cmd>lua vim.diagnostic.goto_prev({severity = vim.diagnostic.severity.ERROR})<cr>",
{ buffer = bufnr, desc = "Previous error" } { buffer = bufnr, desc = "Previous error" }
) )
map( map(
"n", "n",
"]e", "]D",
"<cmd>lua vim.diagnostic.goto_next({severity = vim.diagnostic.severity.ERROR})<cr>", "<cmd>lua vim.diagnostic.goto_next({severity = vim.diagnostic.severity.ERROR})<cr>",
{ buffer = bufnr, desc = "Next error" } { buffer = bufnr, desc = "Next error" }
) )
@ -126,15 +126,29 @@ lsp.setup({
local lspconfig = require("lspconfig") local lspconfig = require("lspconfig")
local python_path
-- ensure python virtualenv is determined automatically on lsp start -- ensure python virtualenv is determined automatically on lsp start
lspconfig.pyright.setup({ lspconfig.pyright.setup({
on_attach = function(client, bufnr) on_attach = function(client, bufnr)
on_attach(client, bufnr) if python_path == nil then
local python_path, _ = require("util").get_python_venv(client.config.root_dir) python_path, _ = require("util").get_python_venv(client.config.root_dir)
vim.notify_once(string.format("[PYTHON VENV]\n%s", python_path)) end
-- print(string.format("[PYTHON VENV]: %s", vim.inspect(python_path)))
client.config.settings.python.pythonPath = python_path client.config.settings.python.pythonPath = python_path
on_attach(client, bufnr)
end, end,
}) })
lspconfig.ruff_lsp.setup({
on_attach = function(client, bufnr)
if python_path == nil then
python_path, _ = require("util").get_python_venv(client.config.root_dir)
end
-- print(string.format("[PYTHON VENV]: %s", vim.inspect(python_path)))
client.config.settings.python.pythonPath = python_path
on_attach(client, bufnr)
end,
})
-- set up arduino with the help of arduino.nvim plugin -- set up arduino with the help of arduino.nvim plugin
if require("util").is_available("arduino") then if require("util").is_available("arduino") then
lspconfig.arduino_language_server.setup({ lspconfig.arduino_language_server.setup({

View file

@ -33,7 +33,6 @@ return {
config = function() config = function()
require("plugins.config.toggleterm") require("plugins.config.toggleterm")
end, end,
lazy = false,
cmd = { "ToggleTerm", "TermExec", "Lazygit", "Pythonterm" }, cmd = { "ToggleTerm", "TermExec", "Lazygit", "Pythonterm" },
}, },
-- colorschemes -- colorschemes
@ -43,4 +42,10 @@ return {
priority = 1000, priority = 1000,
dependencies = { "rktjmp/fwatch.nvim" }, dependencies = { "rktjmp/fwatch.nvim" },
}, },
-- try to avoid putting files in util buffers, e.g. filetree, aerial, undotree, ..
{
'stevearc/stickybuf.nvim',
config = true,
}
} }

View file

@ -55,4 +55,27 @@ return {
ft = { "quarto", "python" }, ft = { "quarto", "python" },
lazy = false, lazy = false,
}, },
-- MARKDOWN ONLY
-- Evaluate markdown code blocks
{
"jubnzv/mdeval.nvim",
cmd = {
"MdEval",
},
ft = { "markdown" },
opts = {
require_confirmation = false,
eval_options = {},
},
lazy = false,
},
{
"AckslD/nvim-FeMaco.lua",
cmd = {
"FeMaco"
},
ft = { "markdown" },
config = true
}
} }

View file

@ -47,6 +47,6 @@ return {
}, },
}) })
end, end,
event = "VeryLazy", event = "InsertEnter",
}, },
} }

View file

@ -8,11 +8,26 @@ return {
"nvim-treesitter/nvim-treesitter", "nvim-treesitter/nvim-treesitter",
"nvim-tree/nvim-web-devicons", "nvim-tree/nvim-web-devicons",
}, },
event = "VeryLazy", cmd = {
"AerialToggle",
"AerialOpen",
"AerialOpenAll",
"AerialClose",
"AerialCloseAll",
"AerialNext",
"AerialPrev",
"AerialGo",
"AerialInfo",
"AerialNavToggle",
"AerialNavOpen",
"AerialNavClose",
},
opts = { opts = {
backends = { "treesitter", "lsp", "markdown", "man" }, backends = { "treesitter", "lsp", "markdown", "man" },
}, },
}, },
-- lsp setup
{ {
"junnplus/lsp-setup.nvim", "junnplus/lsp-setup.nvim",
dependencies = { dependencies = {
@ -51,6 +66,7 @@ return {
require("plugins.config.lsp") require("plugins.config.lsp")
end, end,
}, },
-- completion setup
{ {
"hrsh7th/nvim-cmp", "hrsh7th/nvim-cmp",
branch = "main", branch = "main",
@ -82,7 +98,134 @@ return {
end, end,
event = { "InsertEnter", "CmdlineEnter", "VeryLazy" }, event = { "InsertEnter", "CmdlineEnter", "VeryLazy" },
}, },
-- loading animations for some LSP -- loading animations for some LSP
{ "j-hui/fidget.nvim", config = true, tag = "legacy", event = "VeryLazy" }, { "j-hui/fidget.nvim", config = true, tag = "legacy", event = "VeryLazy" },
-- a pretend-lsp for formatters and linters
-- testing setup
{
"nvim-neotest/neotest",
dependencies = {
"nvim-lua/plenary.nvim",
"nvim-treesitter/nvim-treesitter",
"antoinemadec/FixCursorHold.nvim",
"nvim-neotest/neotest-python",
},
config = function()
require("neotest").setup({
adapters = {
require("neotest-python")({
-- with coverage requires coverage.py and pytest-cov installed
args = { "--cov" },
}),
},
})
local status, wk = pcall(require, "which-key")
if status then
wk.register({ ["<localleader>t"] = { name = "+test" } })
end
end,
ft = { "python" },
keys = {
{
"<leader>st",
[[<cmd>lua require('neotest').summary.toggle()<cr>]],
desc = "toggle test list",
silent = true,
},
{
"<leader>sT",
[[<cmd>lua require('neotest').output_panel.toggle()<cr>]],
desc = "toggle test output",
silent = true,
},
{
"<localleader>to",
[[<cmd>lua require('neotest').output.open()<cr>]],
desc = "toggle test output",
silent = true,
},
{
"<localleader>tt",
[[<cmd>lua require('neotest').run.run()<cr>]],
desc = "run nearest test",
silent = true,
},
{
"<localleader>td",
[[<cmd>lua require('neotest').run.run({strategy = "dap"})<cr>]],
desc = "debug nearest test",
silent = true,
}, -- REQUIRES DAP
{
"<localleader>tT",
[[<cmd>lua require('neotest').run.run(vim.fn.expand("%"))<cr>]],
desc = "test current file",
silent = true,
},
{
"<localleader>tr",
[[<cmd>lua require('neotest').run.run_last()<cr>]],
desc = "re-run last test",
silent = true,
},
{
"<localleader>tw",
[[<cmd>lua require('neotest').watch.toggle()<cr>]],
desc = "watch current test",
silent = true,
},
{
"<localleader>tW",
[[<cmd>lua require('neotest').watch.toggle(vim.fn.expand("%"))<cr>]],
desc = "watch current file",
silent = true,
},
},
},
-- TODO needs to pick up poetry env for python,
-- currently just hard-codes running through poetry
{
"andythigpen/nvim-coverage",
dependencies = {
"nvim-lua/plenary.nvim",
},
config = function()
require("coverage").setup({
lang = { python = { coverage_command = "poetry run coverage json -q -o -" } },
})
end,
ft = { "python" },
cmd = {
"Coverage",
"CoverageLoad",
"CoverageLoadLcov",
"CoverageShow",
"CoverageHide",
"CoverageToggle",
"CoverageClear",
"CoverageSummary",
},
keys = {
{
"<localleader>tp",
[[<cmd>Coverage<cr>]],
desc = "show coverage report",
silent = true,
},
{
"<localleader>tP",
[[<cmd>CoverageToggle<cr>]],
desc = "toggle coverage gutter",
silent = true,
},
{
"<localleader>ts",
[[<cmd>CoverageSummary<cr>]],
desc = "show coverage summary",
silent = true,
},
},
},
} }

View file

@ -12,8 +12,10 @@ return {
require("wrapping").setup({ require("wrapping").setup({
create_keymappings = false, create_keymappings = false,
notify_on_switch = false, notify_on_switch = false,
softener = { markdown = true, text = true, asciidoc = true }
}) })
end, end,
lazy = false
}, },
-- displays prettier headlines mimicking the ones in emacs orgmode -- displays prettier headlines mimicking the ones in emacs orgmode
{ {

View file

@ -55,6 +55,16 @@ return {
dependencies = { dependencies = {
"nvim-lua/plenary.nvim", "nvim-lua/plenary.nvim",
}, },
config = true, event = "VeryLazy", config = true,
keys = {
{
"<leader>su",
function()
require("undotree").toggle()
end,
desc = "toggle undotree",
silent = true,
},
},
}, },
} }

View file

@ -5,10 +5,18 @@ local T = {}
---@param plugin string The plugin to search for ---@param plugin string The plugin to search for
---@return boolean available # Whether the plugin is available ---@return boolean available # Whether the plugin is available
function T.is_available(plugin) function T.is_available(plugin)
local lazy_config_avail, lazy_config = pcall(require, "lazy.core.config") return T.get_plugin(plugin) and true or false
return lazy_config_avail and lazy_config.plugins[plugin] ~= nil
end end
-- Get the plugin file handle if it exists, return nil otherwise
function T.get_plugin(plugin)
local status, lib = pcall(require, plugin)
if(status) then return lib end
return nil
end
-- get the current python environment
-- return its path
function T.get_python_venv(workspace) function T.get_python_venv(workspace)
return require("util.pyenv").get_path(workspace) return require("util.pyenv").get_path(workspace)
end end

View file

@ -186,3 +186,7 @@ Gitea
caramelization caramelization
Maillard Maillard
individualities individualities
vaccilation
SSCM
GSCM
multicriteria

View file

@ -55,10 +55,10 @@ def extract_tags_from(json_obj):
tags = [json_obj['description']] tags = [json_obj['description']]
if 'project' in json_obj: if 'project' in json_obj:
tags.append(json_obj['project']) tags.append(f"#{json_obj['project']}")
if 'tags' in json_obj: if 'tags' in json_obj:
tags.extend(json_obj['tags']) tags.extend([f"+{tag}" for tag in json_obj['tags']])
return tags return tags

View file

@ -56,6 +56,7 @@ c.tabs.title.format = "{index} {audio}{perc}{current_title}"
c.tabs.position = "right" c.tabs.position = "right"
c.tabs.width = "15%" c.tabs.width = "15%"
c.tabs.show = "multiple" c.tabs.show = "multiple"
c.tabs.show_switching_delay = 2000
c.statusbar.show = "always" c.statusbar.show = "always"
c.colors.webpage.bg = "#555555" c.colors.webpage.bg = "#555555"

View file

@ -1,3 +1,5 @@
# disable html5 canvas fingerprinting (at the cost of a couple streaming pages)
c.content.canvas_reading = False
c.content.blocking.enabled = True c.content.blocking.enabled = True
c.content.blocking.method = "both" c.content.blocking.method = "both"
c.content.blocking.adblock.lists = [ c.content.blocking.adblock.lists = [

View file

@ -132,8 +132,8 @@ download() { # 1=url
setup() { setup() {
TEMP_FOLDER="${TEMP_FOLDER:-${HOME}/downloads}" TEMP_FOLDER="${TEMP_FOLDER:-${HOME}/downloads}"
DL_FOLDER="${DL_FOLDER:-${XDG_VIDEOS_DIR:-$HOME/videos}/inbox}" DL_FOLDER="${DL_FOLDER:-${XDG_VIDEOS_DIR:-$HOME/media/videos}/inbox}"
ARCHIVE_FOLDER="${ARCHIVE_FOLDER:-${XDG_VIDEOS_DIR:-$HOME/videos}/archive}" ARCHIVE_FOLDER="${ARCHIVE_FOLDER:-${XDG_VIDEOS_DIR:-$HOME/media/videos}/archive}"
YT_DL_CMD="${YT_DL_CMD:-yt-dlp}" YT_DL_CMD="${YT_DL_CMD:-yt-dlp}"
yt_default_opts=(-f "best[height\<=1080]" --retries 15 --embed-chapters --embed-subs --sub-lang "en,de,es,fr") yt_default_opts=(-f "best[height\<=1080]" --retries 15 --embed-chapters --embed-subs --sub-lang "en,de,es,fr")
declare -a YT_DL_OPTS=${YT_DL_OPTS:-( "${yt_default_opts[@]}" )} declare -a YT_DL_OPTS=${YT_DL_OPTS:-( "${yt_default_opts[@]}" )}

View file

@ -1,31 +0,0 @@
#!/bin/sh
# more usage instructions at https://github.com/clvv/fasd
# exist fasd && eval "$(fasd --init posix-hook posix_alias bash-hook zsh-hook zsh-ccomp zsh-ccomp-install zsh-wcomp zsh-wcomp-install)"
exist fasd && eval "$(fasd --init auto)"
# any
alias a='fasd -a'
# show / search / select
alias s='fasd -si'
# alias d='fasd -d' # directory
# alias f='fasd -f' # file
# alias sd='fasd -sid' # interactive directory selection
# alias sf='fasd -sif' # interactive file selection
# cd, same functionality as j in autojump
alias z='fasd_cd -d'
# cd with interactive selection
alias zz='fasd_cd -d -i'
# from: https://github.com/clvv/fasd/issues/10
# since I can only load auto configuration and have default fasd_cd AND useless aliases
# or manually load the modules and NOT have fasd_cd
# it's easier to use this function
fasd_cd() {
fasd_ret="$(fasd -d "$@")"
if [ -d "$fasd_ret" ]; then
cd "$fasd_ret" || exit
else
printf "%s\n" "$fasd_ret"
fi
unset fasd_ret
}

View file

@ -35,7 +35,7 @@ export BROWSER="qutebrowser"
export TERMINAL="wezterm" export TERMINAL="wezterm"
export PAGER="less" export PAGER="less"
export FILEREADER="zathura" export FILEREADER="sioyek"
export FILEMANAGER="vifm" export FILEMANAGER="vifm"
## gopath ## gopath

View file

@ -24,5 +24,6 @@ if [ -d "$CONFDIR/bash/alias.d" ]; then
unset _alias unset _alias
fi fi
eval "$(zoxide init bash)"
alias ls='ls --color=auto' alias ls='ls --color=auto'
PS1='[\u@\h \W]\$ ' PS1='[\u@\h \W]\$ '

View file

@ -358,7 +358,7 @@ set classify+=' ::*.doc,,*.docx::, ::*.xls,,*.xls[mx]::, ::*.pptx,,*.pp
" Pdf " Pdf
filextype *.pdf filextype *.pdf
\ { view as rich file } \ { view as rich file }
\ zathura %c %i &, apvlv %c, xpdf %c, \ sioyek %c %i, zathura %c %i &, apvlv %c, xpdf %c,
\ { edit text content } \ { edit text content }
\ pdftotext -nopgbrk %c - | nvim \ pdftotext -nopgbrk %c - | nvim
fileviewer *.pdf pdftotext -nopgbrk %c - fileviewer *.pdf pdftotext -nopgbrk %c -
@ -366,14 +366,14 @@ fileviewer *.pdf pdftotext -nopgbrk %c -
" PostScript " PostScript
filextype *.ps,*.eps,*.ps.gz filextype *.ps,*.eps,*.ps.gz
\ {View in zathura} \ {View in zathura}
\ zathura %f, \ sioyek %f, zathura %f,
\ {View in gv} \ {View in gv}
\ gv %c %i &, \ gv %c %i &,
" Djvu " Djvu
filextype *.djvu,*.epub filextype *.djvu,*.epub
\ {View in zathura} \ {View in zathura}
\ zathura %f, \ sioyek %f, zathura %f,
\ {View in apvlv} \ {View in apvlv}
\ apvlv %f, \ apvlv %f,

View file

@ -99,6 +99,8 @@ ENABLE_CORRECTION="true"
# allow moving through directories without prepending cd # allow moving through directories without prepending cd
setopt autocd setopt autocd
eval "$(zoxide init zsh)"
# Speed up autocomplete, force prefix mapping # Speed up autocomplete, force prefix mapping
zstyle ':completion:*' accept-exact '*(N)' zstyle ':completion:*' accept-exact '*(N)'
zstyle ':completion:*' use-cache on zstyle ':completion:*' use-cache on

View file

@ -3,9 +3,9 @@ default-library = main
formater = bbt formater = bbt
local-config-file = .papis.config local-config-file = .papis.config
# opentool = zathura opentool = sioyek
picktool = papis-tui picktool = papis-tui
mark-opener = zathura -P {mark[value]} mark-opener = sioyek --page {mark[value]}
file-browser = vifm file-browser = vifm
# edit info.yaml as new papers are added # edit info.yaml as new papers are added

View file

@ -14,7 +14,10 @@ from papis.database.base import Database
from papis.document import Document from papis.document import Document
parser = argparse.ArgumentParser() parser = argparse.ArgumentParser()
parser.add_argument("query", nargs="*", help="the query to search for") parser.add_argument(
"--count", "-c", help="the query to search for", action="store_true"
)
parser.add_argument("query", nargs="*", help="the query to search for", default="*")
args = parser.parse_args() args = parser.parse_args()
@ -22,7 +25,7 @@ def main(db: Database, args) -> None:
query = " ".join(args.query) query = " ".join(args.query)
docs: list[Document] = db.query(query) docs: list[Document] = db.query(query)
all_tags: set[str] = set() all_tags: dict[str, int] = {}
for doc in docs: for doc in docs:
t: list[str] | str = doc.get("tags", "") t: list[str] | str = doc.get("tags", "")
tags = ( tags = (
@ -30,10 +33,25 @@ def main(db: Database, args) -> None:
) )
for tag in tags: for tag in tags:
all_tags.add(tag) if tag == '':
continue
all_tags[tag] = all_tags.get(tag, 0) + 1
if args.count:
print_tags_and_counts(all_tags)
else:
print_tags_only(all_tags)
def print_tags_only(all_tags):
for tag in sorted(all_tags): for tag in sorted(all_tags):
print(tag) print(tag)
def print_tags_and_counts(all_tags):
for tag, count in sorted(all_tags.items(), key=lambda d: d[1], reverse=True):
if args.count:
print(tag, count)
else:
print(tag)
if __name__ == "__main__": if __name__ == "__main__":
main(database.get(), args) main(database.get(), args)

View file

@ -0,0 +1,30 @@
noop <C-w>
open_document_embedded o
toggle_custom_color <C-r>
goto_begining gg
goto_end G
screen_up <C-u>
screen_down <C-d>
previous_page <C-b>
next_page <C-f>
next_state L
prev_state H
fit_to_page_width S
fit_to_page_width_smart s
fit_to_page_height a
fit_to_page_height_smart A
embed_annotations <C-s>
toggle_statusbar <C-n>
keyboard_select;add_highlight_with_current_type V
regex_search /
copy y
rotate_clockwise R

View file

@ -0,0 +1,26 @@
# START FLAVOURS
# base16-sioyek (https://github.com/loiccoyle/base16-sioyek)
# by Loic Coyle
# Gruvbox dark, soft scheme byDawid Kurek (dawikur@gmail.com), morhetz (https://github.com/morhetz/gruvbox)
custom_background_color #32302f
custom_text_color #ebdbb2
page_separator_color #32302f
search_highlight_color #fabd2f
status_bar_color #32302f
status_bar_text_color #ebdbb2
ui_text_color #ebdbb2
ui_selected_text_color #ebdbb2
ui_background_color #3c3836
ui_selected_background_color #665c54
background_color #32302f
visual_mark_color 0.40 0.36 0.33 0.2
text_highlight_color #665c54
link_highlight_color #83a598
synctex_highlight_color #fb4934
# END FLAVOURS
super_fast_search 1
startup_commands toggle_custom_color

View file

@ -2,6 +2,7 @@
[bibtex](https://en.wikipedia.org/wiki/BibTeX) - plain-text reference management [bibtex](https://en.wikipedia.org/wiki/BibTeX) - plain-text reference management
[zathura](git.pwmt.org) - keyboard-driven PDF reading [zathura](git.pwmt.org) - keyboard-driven PDF reading
[sioyek](http://sioyek.info/) - keyboard-driven PDF reading *and annotating*
This readme is a little out of date, as are the scripts below. This readme is a little out of date, as are the scripts below.
They are old, I used them during my time as a student and they are probably written terribly. They are old, I used them during my time as a student and they are probably written terribly.