Skip to content

Debashich/gocli

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

gocli Todo Manager


CI Go

A Golang based CLI todo manager with JSON persistence and a CI/CD pipeline using GitHub Actions for automated build, linting, and testing.


Features

  • Persistence: Data is saved to todos.json automatically
  • Generics: Uses a generic storage engine for easy extension
  • Table View: Clean terminal output using aquasecurity/table
  • Full CRUD: Add, Edit, Toggle, and Delete tasks

CI/CD

This project uses GitHub Actions:

  • Automated builds on every push
  • Code linting using golangci-lint
  • Running tests
  • Ensuring consistent code quality

Installation

1. Clone the repository

git clone https://github.com/Debashich/goCLI.git
cd goCLI

2. Install dependencies

go mod tidy

3. Build the binary

go build -o todo

Usage

Run using the compiled binary:

./todo

Or directly with Go:

go run .

Commands

Add a new task

./todo -add "Finish Go project"

List all tasks

./todo -list

Toggle completion status

./todo -toggle 0

Edit a task

Format:

index:new text

Example:

./todo -edit "0:Complete the Go CLI tutorial"

Delete a task

./todo -del 0

Help

./todo -h

Project Structure

.
├── .github/
│   └── workflows/
│       └── go.yaml        # GitHub Actions CI pipeline
├── commands.go            # CLI command handling
├── main.go                # Application entry point
├── todo.go                # Core todo logic
├── storage.go             # JSON persistence logic
├── todos.json             # Data storage file
├── go.mod                 # Module definition
├── go.sum                 # Dependencies checksum
└── README.md              # Project documentation

License

This project is open-source and available under the MIT License.

About

Lightweight CLI todo application built with Go, featuring persistent storage and a CI/CD workflow using GitHub Actions for automated builds, linting, and validation.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages