ScratchPad
ScratchPad copied to clipboard
[Feature Request]: Scratchpad for each directory option
I think it would be cool to have a feature that can be enabled to have a scratchpad for each directory the user is in. This could also be used with the daily option as well, where each scratchpad in the directory is cleared each day.
Also, another thing that isn't the biggest deal in the world would be an option to autofocus the buffer whenever the ScratchPad
command is ran
A scratchpad for every directory would be excessive for me, but one for each repository would be nice.
There could be multiple :ScratchPad
command options for opening a scratchpad in common locations:
-
:ScratchPad git
:$(git rev-parse --show-toplevel)/.scratchpad
-
:ScratchPad pwd
:$(pwd)/.scratchpad
-
:ScratchPad daily
:~/.daily_scratchpad/YYY-MM-DD
-
:ScratchPad user
:~/.scratchpad
That could definitely be useful. If I have some spare time I might try it, but feel free to throw together a PR if you're interested.
As to your suggested implementation, I personally would prefer an api where you set g:scratchpad_location
with either a path, or git
, daily
or pwd
, or even an arbitrary lua function with some more complex resolution strategy.