A simple command-line todo application
Project description
๐ Todo CLI X
A command-line Todo application built in Python, designed as a progressive learning project.
๐๐พ See the project Roadmap
๐ Learning Objectives
- Learn Python through hands-on practice
- Apply a clear and professional project methodology
- Deepen understanding of core concepts (modules, functions, data structures, etc.)
- Get introduced to modern tools in the Python ecosystem:
uvfor dependency managementpyproject.tomlfor project configuration- Unit testing
argparsefor command-line interfaces- And other tools/modules...
- GitHub Actions
๐ Project Status
- โ Git repository initialized
- โ Python environment managed with UV
- โ Core logic implemented (add, list, complete, delete, clear)
- โ Priority filtering and sorting
- โ
Fully tested with
pytest - โ Continuous Integration (CI) set up
- โ CLI welcome screen and helpful feedback
- โ
Task metadata:
createdandduedates - โ
Enhanced list display with
--verbose - โ Display of due date by default
- โ Support for multi-ID delete
- โ Tagging system for tasks (e.g. --tags work,urgent)
- โ Filter tasks by tag(s) with --tags option
Quick Install (Recommended)
If you just want to use the todo CLI tool without cloning the repository, you can install it globally using pipx:
brew install pipx
pipx ensurepath
pipx install todo-cli-x
Once installed, run the CLI from anywhere in your terminal:
todo --help
todo add "Submit report" --priority high --due 2025-06-10
todo add "Refactor API" --priority high --due 2025-06-30 --tags dev,urgent
todo list
todo list --verbose
todo list --tags dev
To upgrade later:
pipx upgrade todo-cli-x
Local Development Setup
๐ Project Structure
todo-cli/
โโโ src/
โ โโโ todo_cli/ # Main application package
โ โโโ __init__.py # Marks the directory as a Python package
โ โโโ core.py # Business logic: add, delete, list, etc.
โ โโโ main.py # CLI entry point (parses commands and calls core logic)
โโโ tests/
โ โโโ test_core.py # Unit tests for core logic (add, list, complete, etc.)
โ โโโ test_utils.py # Unit tests for utility functions (formatting, display, etc.)
โโโ pyproject.toml # Project configuration (metadata, dependencies, CLI script)
โโโ uv.lock # Lock file generated by UV (resolved dependencies)
โโโ README.md # Project documentation and usage instructions
โโโ LICENSE # MIT license file
โโโ .gitignore # Git ignored files and directories
โโโ .python-version # Python version used for the virtual environment (3.11)
Clone the repository:
git clone https://github.com/vidjinnangni/todo-cli.git
cd todo-cli
Set up the environment using uv:
uv sync
(Optional) Activate the virtual environment manually:
(macOS and Linux)
source .venv/bin/activate
Task Storage
- All tasks are stored in a local file named
todo_data.json(automatically created when needed). - This file is excluded from version control (
.gitignore) to avoid polluting the repository with user data. - You can see an example of the file format in
examples/todo_data.example.json:
[
{
"id": 1,
"text": "Buy milk",
"done": false,
"priority": "medium",
"created": "2025-06-01T12:00:00+00:00",
"due": "2025-06-15",
"tags": ["shopping", "errands"]
}
]
Usage
Run the CLI tool without activating the environment:
uv run todo add "Submit report" --priority high --due 2025-06-10
uv run todo add "Refactor API" --priority high --due 2025-06-30 --tags dev,urgent
uv run todo list
uv run todo list --verbose
uv run todo list --tags dev
command
todo list
command
todo list --verbose
Or activate the environment and use todo directly:
source .venv/bin/activate
todo add "Submit report" --priority high --due 2025-06-10
todo add "Refactor API" --priority high --due 2025-06-30 --tags dev,urgent
todo list --tags dev
๐ Learn how the CLI is implemented internally โ CLI Architecture
Running Tests
First, install all dependencies:
uv sync --extra dev
Then run the tests:
uv run pytest
Or:
source .venv/bin/activate
pytest
โ๏ธ License
This project is licensed under the MIT License. See the LICENSE file for more information.
๐ Contributions Welcome
Contributions are not only welcome โ theyโre encouraged! Whether youโre a beginner looking to learn or an experienced developer with suggestions, ideas, or improvements, youโre invited to participate.
Hereโs how you can contribute:
- ๐ Report bugs โ Found something that doesnโt work as expected? Open an issue!
- โจ Suggest features โ Got an idea to make the tool more useful? Share it in the discussions or issues.
- ๐งน Improve the code โ Clean up logic, refactor modules, or enhance test coverage.
- ๐ Enhance documentation โ Clear, friendly documentation helps everyone.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file todo_cli_x-1.1.1.tar.gz.
File metadata
- Download URL: todo_cli_x-1.1.1.tar.gz
- Upload date:
- Size: 14.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.7.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
cd774f48796489227be52050df639be665e9bac185425096a581dfe5811eb7cf
|
|
| MD5 |
d376b9f5498e0111d7191ce629732a5e
|
|
| BLAKE2b-256 |
4541714d983f29981d52b4dbbe5287aa594070b9e9f77b06ec507ba52597e2f2
|
File details
Details for the file todo_cli_x-1.1.1-py3-none-any.whl.
File metadata
- Download URL: todo_cli_x-1.1.1-py3-none-any.whl
- Upload date:
- Size: 10.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.7.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9460b8e8308cc90520cc94d69f94f558d01e12fae63f4a3a28c7a6721cf49456
|
|
| MD5 |
1bd7c7b53a93503394a019e270a4657c
|
|
| BLAKE2b-256 |
69a3450a8ab095b4ff38fa80b9d24b295493ebf2477dbdfaeb53f63376a3195b
|