taskpad-cli is a lightweight, session-based task tracker built for the command line. It allows you to log tasks, assign priorities, and estimate completion times—all within a single terminal session.
Built as a weekend project to strengthen C++ fundamentals and Git workflows, taskpad-cli uses vectors, loops, and conditionals, while providing a practical tool for managing short-term work sessions. Future versions could evolve into a full-featured TUI app with file persistance, ncurses integration, and Pomodoro timers.
- Set up
main()with awhile (running)loop. - Display a session-focused menu:
- Add Task
- View Session Tasks
- View Session Summary
- Quit Session
- Use an
int choiceandif / else ifto control logic. - Add
bool running = true;to control the loop lifecycle.
-
std::vector<std::string> tasks;→ holds task names. -
std::vector<std::string> priorities;→ holds Low/Medium/High for each task. -
std::vector<int> times;→ holds estimated minutes per task. - Make sure all vectors’ indices align (index
irepresents the same task across all three).
- Prompt: “Enter task name (for this session):”
- Prompt: “Priority (Low, Medium, High):”
- Optional: Validate input is one of the three.
- Prompt: “Estimated time (minutes):”
- Reject negative values with an error message.
- Push values into respective vectors.
- Print: “Task added to session.”
- If empty: print “No tasks logged for this session.”
- Otherwise: loop through tasks and print:
- Index number
- Task name
- Priority
- Estimated time (min)
- Keep output clear and session-oriented.
- If empty: print “No tasks recorded.”
- Loop to calculate:
- Total number of tasks.
- Total estimated time (sum of all times).
- Also loop with conditionals to track total time per priority level.
- Print a clean summary:
- “Session Total Tasks: X”
- “Session Total Time: Y minutes”
- Time breakdown by priority.
- Set
running = false;and print:- “Ending session. Goodbye!”
- Allow the program to exit gracefully.
- Validate menu input: only
1–4accepted. - Print “Invalid choice, try again” for bad input.
- (Optional) Validate priority input and re-prompt on errors.
- After viewing summary, display average time per task.
- Print a warning if total session time exceeds a chosen threshold (e.g., 480 minutes).
- Add a session start time and end time printout (use
ctimelater when you learn it).
- Placeholder comment in code:
// Pomodoro feature to be added later.
- This keeps the code ready to evolve when you learn
chronoand more advanced loops.