Skip to content

binadrish/Task-Tracker-Py

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Task Tracker CLI

A simple command-line interface (CLI) application for tracking and managing your tasks. This project helps you organize what you need to do, what you're currently working on, and what you've completed.

Features

  • ✅ Add new tasks
  • ✏️ Update task descriptions
  • 🗑️ Delete tasks
  • 📋 List all tasks
  • 🔄 Mark tasks as TODO, IN_PROGRESS, or DONE
  • 🔍 Filter tasks by status
  • 💾 Persistent storage using JSON file

Requirements

  • Python 3.13 or higher
  • No external dependencies (uses only Python standard library)

Installation

  1. Clone this repository:
git clone <repository-url>
cd task-tracker-cli
  1. Install the package using uv:
uv install

Or install it in development mode:

uv install -e .

Usage

The application provides several commands to manage your tasks:

Add a Task

task-cli add "Your task description"

List All Tasks

task-cli list

Delete a Task

task-cli delete <task-id>

Update Task Description

task-cli update <task-id> "New description"

Mark Task Status

# Mark as in progress
task-cli mark-in-progress <task-id>

# Mark as done
task-cli mark-done <task-id>

# Mark as todo
task-cli mark-todo <task-id>

List Tasks by Status

# List all TODO tasks
task-cli list-by TODO

# List all IN_PROGRESS tasks
task-cli list-by IN_PROGRESS

# List all DONE tasks
task-cli list-by DONE

Examples

# Add a new task
task-cli add "Complete the project documentation"

# List all tasks
task-cli list

# Mark task as in progress
task-cli mark-in-progress 1

# Update task description
task-cli update 1 "Complete the README documentation"

# Mark task as done
task-cli mark-done 1

# List only completed tasks
task-cli list-by DONE

# Delete a task
task-cli delete 1

Data Storage

Tasks are stored in a task_tracker.json file in the current directory. The file is automatically created if it doesn't exist. The JSON structure includes:

{
    "last_id": 1,
    "tasks": [
        {
            "id": 1,
            "description": "Your task description",
            "status": "TODO",
            "created_at": "2025-07-08T20:57:31.927468",
            "updated_at": "2025-07-08T20:57:31.927468"
        }
    ]
}

Project Structure

task-tracker-cli/
├── src/
│   ├── __init__.py
│   ├── cli.py          # Command-line interface
│   └── models.py       # Task and TaskManager classes
├── pyproject.toml      # Project configuration
├── uv.lock            # Dependency lock file
├── task_tracker.json  # Task storage (auto-generated)
└── README.md

Task Status

Tasks can have one of three statuses:

  • TODO - Task is not started
  • IN_PROGRESS - Task is currently being worked on
  • DONE - Task is completed

Error Handling

The application handles various error cases gracefully:

  • Invalid task IDs
  • Empty task descriptions
  • File system errors
  • Invalid status values

Development

The project is built with:

  • Python 3.13
  • Standard library only (no external dependencies)
  • Object-oriented design with proper error handling
  • JSON file-based persistence

Contributing

Feel free to submit issues and enhancement requests!

License

This project is open source and available under the MIT License.

About

A simple command-line interface (CLI) application for tracking and managing your tasks.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages