chrisbirster / taskcli

A tutorial for building a Taskwarrior-inspired task tracker in Go using glamorous CLI libraries

Home Page:https://youtu.be/yiFhQGJeRJk

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Creating a Task Manager (a Charm Tutorial)

This project is inspired by the incredible work on Task Warrior, an open source CLI task manager. I use this project quite a bit for managing my projects without leaving the safety and comfort of my terminal. (⌐■_■)

We built a kanban board TUI in a previous tutorial, so the idea here is that we're going to build a task management CLI with Cobra that has Lip Gloss styles and can be viewed using our kanban board.

Note: We walk through the code explaining each and every piece of it in the corresponding video for this tutorial. Enjoy!!

Here's the plan:

Checklist

If you're following along with our tutorials for this project, or even if you want to try and tackle it yourself first, then look at our solutions, here's what you need to do:

Data Storage

  • set up a SQLite database
    • open SQLite DB
    • add task
    • delete task
    • edit task
    • get tasks

Making a CLI with Cobra

  • add CLI
    • add task
    • delete task
    • edit task
    • get tasks

Add a little... Je ne sais quoi

Project Layout

db.go - here we create our custom task struct and our data layer.

main.go - our main file handles our initial setup including opening a database and setting the data path for our application.

cmds.go - this is where we do all of our Cobra commands and setup for our CLI.

About

A tutorial for building a Taskwarrior-inspired task tracker in Go using glamorous CLI libraries

https://youtu.be/yiFhQGJeRJk


Languages

Language:Go 100.0%