https://github.com/strvcom/strv-backend-go-tea
Universal set of tools to make development in Go as simple as making a cup of tea.
https://github.com/strvcom/strv-backend-go-tea
cmd go golang tea tools util
Last synced: 8 months ago
JSON representation
Universal set of tools to make development in Go as simple as making a cup of tea.
- Host: GitHub
- URL: https://github.com/strvcom/strv-backend-go-tea
- Owner: strvcom
- License: bsd-3-clause
- Created: 2022-06-20T12:35:21.000Z (almost 4 years ago)
- Default Branch: master
- Last Pushed: 2025-08-19T07:09:01.000Z (10 months ago)
- Last Synced: 2025-08-20T08:59:46.012Z (10 months ago)
- Topics: cmd, go, golang, tea, tools, util
- Language: Go
- Homepage: https://go.strv.io
- Size: 168 KB
- Stars: 4
- Watchers: 19
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
- Codeowners: CODEOWNERS
Awesome Lists containing this project
README
# STRV tea
![Latest release][release]
[![codecov][codecov-img]][codecov]
![GitHub][license]
Universal set of tools to make development in Go as simple as making a cup of tea.
## Installation
The most simple way to install tea is by Go native installation functionality. Example:
```shell
$ go install go.strv.io/tea/cmd/tea@${version:-latest}
```
Version points to a stable [release](https://github.com/strvcom/strv-backend-go-tea/releases).
## Commands
For detailed description of each command or global options, run the command with `-h` argument.
### version
Prints tea version and ends.
#### Example
```shell
$ tea version
$ 1.0.0
```
### gen
This command provides a set of tools for code generating.
Subcommand `id` generates useful methods for serialization/deserialization of IDs within Go apps. Example:
```shell
$ tea gen id -i ./id.go -o ./id_gen.go
```
This subcommand can also be used as an embedded go generator. Example:
id.go:
```go
package id
import (
"github.com/google/uuid"
)
//go:generate tea gen id -i ./id.go -o ./id_gen.go
type (
User uint64
RefreshToken uuid.UUID
DeviceIdentifier string
)
```
After triggering `go generate ./...` within an app, methods `MarshalText` and `UnmarshalText` along with other useful functions are generated.
[release]: https://img.shields.io/github/v/release/strvcom/strv-backend-go-tea
[codecov]: https://codecov.io/gh/strvcom/strv-backend-go-tea
[codecov-img]: https://codecov.io/gh/strvcom/strv-backend-go-tea/branch/master/graph/badge.svg?token=A7QFX32CFF
[license]: https://img.shields.io/github/license/strvcom/strv-backend-go-tea