A simple command-line interface (CLI) todo application that is POSIX-compliant. This app allows you to manage your tasks efficiently from the terminal.
- Add tasks with optional tags
- List tasks (with filters for completed/incomplete and tags)
- Delete tasks
- Mark tasks as completed
- Edit task titles and tags
- Search tasks by title or tags
- List all tags used in tasks
- Configurable database location
- Automatic tracking of creation and update dates
- Notifications (coming soon)
Tasks are stored in a local SQLite database. The default location is ~/.todo.db, but this can be configured. Each task includes:
- Title
- Completion status
- Creation date
- Last update date
- Tags (optional)
The app uses a configuration file located at ~/.todo_config.json. You can view and modify the configuration using the config command:
- View current configuration:
./todo.py config --show - Set a configuration value:
./todo.py config --set db_file /path/to/your/database.db
- Ensure you have Python 3.6+ installed on your system.
- Clone this repository:
git clone https://github.com/yourusername/posix-cli-todo.git cd posix-cli-todo - Make the script executable:
chmod +x todo.py - (Optional) Create a symlink to run the app from anywhere:
sudo ln -s $(pwd)/todo.py /usr/local/bin/todo
Run ./todo.py (or just todo if you created a symlink) followed by a command:
add: Add a new tasklist: List tasksdelete: Delete a taskcomplete: Mark a task as completededit: Edit a task's title or tagssearch: Search for taskstags: List all tagsconfig: Manage configuration
For detailed help on each command, use:
./todo.py <command> --help
-
Add a task:
./todo.py add "Buy groceries" --tags shopping,food -
List all tasks:
./todo.py list -
List only incomplete tasks with a specific tag:
./todo.py list --incomplete --tags shopping -
Mark a task as completed:
./todo.py complete 1 -
Edit a task:
./todo.py edit 2 "Buy organic groceries" --tags shopping,organic -
Search for tasks:
./todo.py search "groceries" -
List all tags:
./todo.py tags -
Change the database location:
./todo.py config --set db_file /path/to/your/database.db