Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/kitagry/go-todotxt

Simple todo.txt library for Go
https://github.com/kitagry/go-todotxt

golang

Last synced: 15 days ago
JSON representation

Simple todo.txt library for Go

Awesome Lists containing this project

README

        

# go-todotxt

Simple todo.txt library.

## Usage

```go
import "github.com/kitagry/go-todotxt"

f, err := os.Open("todo.txt")
r := todotxt.NewReader(f)
tasks, err := r.ReadAll()

for _, task := range tasks {
task.SetDescription(task.Description() + " +Project")
}

f, err := os.Write("todo.txt")
w := todotxt.NewWriter(f)
w.WriteAll(tasks)
```

## Tools

### Install

```
$ cd cmd/todotxt
$ go install
```

![go-todotxt](https://user-images.githubusercontent.com/21323222/74706397-3cdef380-525a-11ea-9877-458ae3b6cebd.gif)

## License

MIT

## Author

Ryo Kitagawa