Skip to content
This repository has been archived by the owner on Dec 18, 2024. It is now read-only.

duersjefen/habit-tracking-app

Repository files navigation

Habit Tracking Application

Introduction

This Habit Tracking Application allows users to create, manage, and analyze their daily and weekly habits through a command-line interface.

Installation

  1. Clone the repository or download the source code.
  2. Ensure you have Python 3.7 or later installed.
  3. Install required packages:
    pip install -r requirements.txt

Initialize the database:

python main.py

Usage

Create a Habit

python main.py create --name "Exercise" --periodicity "daily"

Complete a Habit

python main.py complete --name "Exercise"

List Habits

List all habits:

python main.py list

List habits filtered by periodicity:

python main.py list --periodicity "daily"

Delete a Habit

python main.py delete --name "Exercise"

Analyze Habits

Get the habit with the longest streak:

python main.py analyze --longest-streak

Get the longest streak for a specific habit:

python main.py analyze --habit-streak "Exercise"

Predefined Habits

The application comes with 5 predefined habits. To load them, ensure the database is initialized, and the habits are inserted into the database.

Running Tests

Navigate to the project's root directory and run:

python -m unittest discover tests

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages