Awesome
<div align = "center"> <h1><a href="https://github.com/2kabhishek/tdo">tdo</a></h1> <a href="https://github.com/2KAbhishek/tdo/blob/main/LICENSE"> <img alt="License" src="https://img.shields.io/github/license/2kabhishek/tdo?style=flat&color=eee&label="> </a> <a href="https://github.com/2KAbhishek/tdo/graphs/contributors"> <img alt="People" src="https://img.shields.io/github/contributors/2kabhishek/tdo?style=flat&color=ffaaf2&label=People"> </a> <a href="https://github.com/2KAbhishek/tdo/stargazers"> <img alt="Stars" src="https://img.shields.io/github/stars/2kabhishek/tdo?style=flat&color=98c379&label=Stars"></a> <a href="https://github.com/2KAbhishek/tdo/network/members"> <img alt="Forks" src="https://img.shields.io/github/forks/2kabhishek/tdo?style=flat&color=66a8e0&label=Forks"> </a> <a href="https://github.com/2KAbhishek/tdo/watchers"> <img alt="Watches" src="https://img.shields.io/github/watchers/2kabhishek/tdo?style=flat&color=f5d08b&label=Watches"> </a> <a href="https://github.com/2KAbhishek/tdo/pulse"> <img alt="Last Updated" src="https://img.shields.io/github/last-commit/2kabhishek/tdo?style=flat&color=e06c75&label="> </a> <h3>Fast & Simple Note Taking! šš</h3> <figure> <img src="images/screenshot.jpg" alt="tdo in action"> <br/> <figcaption>tdo in action</figcaption> </figure> </div>tdo is a opinionated, command line based note-taking system. Demo video
āØ Features
- Can help you manage a daily log, todos, journal and notes
- Review pending and upcoming todos, past journal entries and more
- Integrates with git to commit and backup your notes automatically, check tdo.nvim for neovim integration
- Has interactive fuzzy searching capabilities powered by fzf
- Can integrate with other tools in pipes and subshells for extended functionality
- Supports all editors, set
$EDITOR
to your choice
ā” Setup
š Requirements
- ripgrep, fzf
- bat (optional, for syntax highlighting in search)
- coreutils (required on macOS, for gdate command)
š» Installation
git clone https://github.com/2kabhishek/tdo
cd tdo
./install.sh
š¦ Environment Variables
-
NOTES_DIR
should point to your notes directory -
TODOS_DIR
optional, should point to your todos directory, default:NOTES_DIR/todos
-
JOURNAL_DIR
optional, should point to your journal directory, default:NOTES_DIR/entries
-
EDITOR
set to your choice of editor
š Manual Installation
If you want to customize the setup or are facing issues with installation, you can set up tdo manually.
Change these commands according to your needs.
# Link tdo to a directory that's in PATH (~/.local/bin here)
ln -sfnv "$PWD/tdo.sh" ~/.local/bin/tdo
# Create a notes dir if not already present
mkdir -p $HOME/Projects/Notes
# Add the NOTES_DIR env var to your shell config ~/.bashrc, ~/.zshrc etc
echo "NOTES_DIR=$HOME/Projects/Notes" >> ~/.zshrc
# Add sample templates to your NOTES_DIR
cp -irv templates $NOTES_DIR
# Reload shell config
source ~/.zshrc
š¾ Git Integration
If you want to sync your notes across devices, you can set up a git repo on the $NOTES_DIR and add GitHub/GitLab as remote.
cd $NOTES_DIR
git init
git add .
git commit -m 'init: notes'
git remote add origin <your-remote-git-url>
git push origin main
tdo will automatically commit every change with a timestamp like 03 Feb 11:33
as commit message.
š Usage
If you use Neovim, I highly recommend using tdo.nvim, it seamlessly integrates tdo
and nvim
and adds some useful features on top.
tdo
to open today's todostdo <offset_days>
to open todos fromoffset_days
in the past or future, e.g:tdo 1
,tdo -2
tdo <note_title>
to open or create anote_tile.md
note, use folder names to categorise notes, e.g:tdo tech/vim-tips
tdo note
ortdo n
to create a new note with the current timestamp indrafts
tdo entry
ortdo e
to open today's journal entrytdo entry <offset_days>
to open journal entry fromoffset_days
in the past or future, e.g:tdo e -3
tdo find <text>
ortdo f
to interactively search fortext
in all your notestdo find
without any search term to review all your notestdo todo
ortdo t
to show all your pending todostdo commit <path>
ortdo c
to commit changes in path, happens automatically, needed for plugins and integrations
Run
tdo h
to get help info on the command line
š Dir Structure
tdo
expects an opinionated directory structure to function.
- Notes live in the
notes
sub-dir, use these for long term knowledge management, second brain - Notes use the templates/note.md file as template
- Todos live in the
todos
sub-dir, use these for short term notes, daily todos - Todos use the templates/todo.md file as template
- Journal entries live in
entries
sub-dir, use these for personal notes, life logging - Journal entries use the templates/entry.md file as template
āāā todos
āĀ Ā āāā 2023
āĀ Ā āāā 11
āĀ Ā Ā Ā āāā 2023-11-29.md
āāā entries
āĀ Ā āāā 2024
āĀ Ā āāā 02
āĀ Ā Ā Ā āāā 2024-02-03.md
āāā notes
āĀ Ā āāā tech
āĀ Ā Ā Ā āāā quit-vim.md
āĀ Ā Ā Ā āāā arch-btw.md
āāā templates
Ā Ā āāā entry.md
Ā Ā āāā note.md
Ā Ā āāā todo.md
āļø Configuration
You can configure tdo
by either defining environment variables or via a $HOME/.config/tdorc
file.
ADD_ENTRY_TIMESTAMP
[boolean]
: Whether to add a time stamp when usingtdo entry
ortdo e
.ADD_NEW_NOTE_TIMESTAMP
[boolean]
: Whether to add a time stamp when creating new notes withtdo <note_title>
.FILE_NAME_AS_TITLE
[boolean]
: Whether to add the file name as title when creating new notes withtdo <note_title>
. Iftrue
, then it adds<note_title>
as a markdown title in the first line of the new note.ENTRY_TIMESTAMP_FORMAT
[string]
: can be any bash string such as a date format expression. It is ignored ifADD_ENTRY_TIMESTAMP
is set tofalse
.NOTE_TIMESTAMP_FORMAT
([string]
: can be any bash string such as a date format expression. It is ignored ifADD_NEW_NOTE_TIMESTAMP
is set tofalse
.
Default Configs
ADD_ENTRY_TIMESTAMP=true
ADD_NEW_NOTE_TIMESTAMP=false
FILE_NAME_AS_TITLE=false
# Reads ## Mon, 12:00 PM
ENTRY_TIMESTAMP_FORMAT="## %a, %I:%M %p"
# Reads ## Fri. Apr 06, 2024 - 06:48 PM
NOTE_TIMESTAMP_FORMAT="## %a. %b %d, %Y - %I:%M %p"
configs defined in
tdorc
will override corresponding environment variables
šļø What's Next
You tell me!
š§āš» Behind The Code
š Inspiration
After trying out every note management system under the sun I had decided on using plain markdown notes powered by nvim2k.
tdo is a spiritual successor and complimentary tool to that, taking the same principles and making it more accessible and simple.
š More CLI Tools
- cmtr ā Fast git commits
- mkrepo ā Spin up new GitHub repos from the CLI
- ghpm ā Manage all your GitHub repos
- gsync ā Sync your git repos
š§° Tooling
- dots2k ā Dev Environment
- nvim2k ā Personalized Editor
- sway2k ā Desktop Environment
- qute2k ā Personalized Browser
<strong>ā hit the star button if you found this useful ā</strong><br>
<a href="https://github.com/2KAbhishek/tdo">Source</a> | <a href="https://2kabhishek.github.io/blog" target="_blank">Blog </a> | <a href="https://twitter.com/2kabhishek" target="_blank">Twitter </a> | <a href="https://linkedin.com/in/2kabhishek" target="_blank">LinkedIn </a> | <a href="https://2kabhishek.github.io/links" target="_blank">More Links </a> | <a href="https://2kabhishek.github.io/projects" target="_blank">Other Projects </a>
</div>