This is the best way to make CLIs in GO - Cobra & Pterm

Описание к видео This is the best way to make CLIs in GO - Cobra & Pterm

In this video, we dive into the basics of creating a CLI in Go. Go is the perfect language to make a CLI. Not only it's super simple, but also many frameworks are ready to make CLIs and make things very easy.
I'll show you how to use Cobra and how to use PTerm to make a simple CLI that will accept user input and save it to database. We will also add another command to list all the entries in the database and show it in a nice table.

Cobra - https://cobra.dev/
Pterm - https://pterm.sh/

Blog Post: https://mightytuts.com/blog/golang-cl...

Timestamps:
0:00 - Introduction
1:38 - Introduction to Cobra
5:46 - Working with Flags
7:38 - Adding parent command
11:30 - Adding child command
13:40 - Adding Pterm and accepting input
18:29 - Setting up database
23:30 - Adding the list command
25:30 - Displaying the data in a table
28:00 - Outro

Tools I use:
- Helix Editor
- Zellij terminal mux
- Kitty terminal
- Catpuccin Mocha everywhere
- Mac mini M2
======================================
#datascience #datastructures #algortihm #coding #softwareengineer #golang #beginner

🌐 www.rovn.ai
🌐 www.mightytuts.com
𝒳   / mahmmousa  
🧑🏼‍💻 Github https://github.com/ms-mousa

Комментарии

Информация по комментариям в разработке