When you come across a issue and solve and try to document it for future or even make a to do list of in terminal ? what do you use? I have been trying spacemacs but having trouble getting used to the point where I can use it in my everyday routine.Im a vim (not a hardcore vim user) but my most work does revolve working in terminal so wanted to make my documentation /schedule in terminal rather than opening a new app.
Can vim be used for this?
For further actions, you may consider blocking this person and/or reporting abuse
Top comments (8)
Short answer: yes, there are a couple of ways you could accomplish this depending on the experience you want to have and trade-offs you're willing to make.
Long answer:
Minimal Approach
I use the official GitHub CLI
gh
for this and keep track of my notes/to-dos in a private gist.For example, you could maintain both notes & to-do's in 1 gist, like:
Then to edit them later:
With this basic
gh
familiarity, you can write some bash shell scripts to simplify managing notes & to-do's, like:You can also write a simple Vim command to manage notes/to-dos from within Vim, like:
This minimal approach resembles the unix philosophy where you use specialized tools that are good at one thing and stitch them together to accomplish something productive, extensive, and re-usable. The beauty of it shines when you realize the following:
export EDITOR="..."
environment variable.tmux
, you can create keybindings to call it from anywhere, e.g.bind-key C-t split-window 'gh gist edit 123abc456def'
to launch it with<prefix> + <Ctrl-T>
. If you use VSCode, you can do the same with a Custom Task or a Gist vscode plugin. And so on...Bonus: I use this method for blog posts. I start by dumping thoughts/outlines in markdown file, then use
gh gist create /path/to/file.md
, continue to work on it over days/weeks/months until it is done, then publish it to GitHub Pages and/or to dev.to.Vim Plugin Approach
There are a number of vim plugins for note-taking. I personally have used vimwiki in the past, but there are more options, like vim-dotoo.
This reddit post from 6 years ago might be relevant.
The benefit of this approach is that note editing and management is a lot more integrated with Vim (e.g. keybindings to speed up common operations) at the cost of being re-usable via shell scripts or if you use a different editor later.
Yes I also work in terminal on everyday basis and using Vim for make todoes is a very simple and fast way ;-)
Do you use any vim plugins to make todoes or anything as such?
No I am not using any plugin.
I only create in plain text something like this:
and with 'R' key I replace blank space by 'x' between brackets.
I've used todo.txt in the past. It's a simple text-based todo app with a command line tool: github.com/todotxt/todo.txt-cli/re...
I don't have the habit of taking notes but I'm aware of some vim plugins made for that.
I will be sure to check these out! I was trying to learn spacemacs but the key bindings are not that intuitive to me.