Skip to content

NutriFitCLI (Nutirition Fitness CLI) - a meal and exercise tracker that displays information on food and calories consumed and includes a list of activates done on any given day if information has been logged.

Notifications You must be signed in to change notification settings

suhas-sunder/NutriFitCLI

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

83 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

NutriFitCLI (Nutirition Fitness CLI)

Description

This is a meal and exercise tracking application that allows users to add/remove meal logs, add/remove exercise logs, view logs by date, view calories burned by day/month, and preview a monthly visual calendar for logged activities.

Additional info:

  • Developed in Python and runs from the Command Line Interface (CLI) (includig Linux/Ubuntu).
  • Utilizes python modules & consists of multiple source files.
  • Covers advanced features covered in ENGR 5200G including arrays, for loop, while loop, switch statements, modules, classes, constructors, functions, objects, and more!

Why it was developed:

The idea seems complex enough to incorporate a lot of elements we explored in class, and would make for a great addition to my portfolio. Additionally, this is an idea/application I have not explored before, and could be a project that could potentially build out further into fully functional web or mobile application.

Architectural Diagram:

image

How to run this application:

  • Download the repo and save the folder in the appropriate directory or clone the repo using git clone <repository-url>: Git Clone
  • Open Ubuntu/Linux terminal and navigate to the directory with the downloaded folder cd path/to/repo
  • Type ./main.py in the command line to run the program. If ./main.py does not work, try running it with Python explicitly python3 main.py ~ (Replace python3 with your Python version as needed.)

Challenges:

  • Handeling datetime conversions was tricky, especially when generating the calendar with appropriate dates.
  • I used a JSON data set instead of a free/demo API. OpenFoodFacts API returned poor results. API Ninjas worked well, but calorie data was hidden behind pay wall. FatSecret required Oauth2 setup which seemed unnecessairly complex.
  • I ended up with a lot of redundant code that can be better optimized given enough time.

Future enhancements:

  • Can build out the application to be functional outside of a CLI for real world use cases. eg. Web or mobile application.
  • Interactive calendar, so that users can click on dates and navigate via calendar buttons or drop-downs instead of manually entering dates.
  • Complex activity logging with graphs and other advanced features. Also, more intuitive navigation between menu and sections. Testing (Unit, integration, etc.)
  • API integration & connection to a relational database (SQL, PostgreSQL, etc.)

Application Preview (Menu(s) & Calendar output)

image image

Sample Output

About

NutriFitCLI (Nutirition Fitness CLI) - a meal and exercise tracker that displays information on food and calories consumed and includes a list of activates done on any given day if information has been logged.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages