Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/igolaizola/webcli
Automatic web UI on top of a golang CLI
https://github.com/igolaizola/webcli
cli golang gui ui web webcli
Last synced: about 1 month ago
JSON representation
Automatic web UI on top of a golang CLI
- Host: GitHub
- URL: https://github.com/igolaizola/webcli
- Owner: igolaizola
- License: mit
- Created: 2024-05-23T14:42:41.000Z (8 months ago)
- Default Branch: main
- Last Pushed: 2024-06-27T20:33:19.000Z (7 months ago)
- Last Synced: 2024-11-26T23:34:56.008Z (about 1 month ago)
- Topics: cli, golang, gui, ui, web, webcli
- Language: Go
- Homepage:
- Size: 577 KB
- Stars: 8
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# webcli đđĨī¸
**webcli** is a tool to generate an automatic web UI on top of a Golang CLI
## đ Features
- List all commands and subcommands
- Edit the flags of the commands using input fields
- Launch commands in the background
- See the output of the commands in real-time
- List and view the output of all the commands launched
- Load command flags from configuration files
- Save command flags to configuration files## đ Compatibility
The tool is directly compatible with `github.com/peterbourgon/ff/v3` and `github.com/spf13/cobra` libraries, using `github.com/igolaizola/webcli/pkg/webff` and `github.com/igolaizola/webcli/pkg/webcobra` respectively.
You can also directly use the `github.com/igolaizola/webcli` package and pass your commands as `webcli.Command` to the `webcli.New` function.
## đšī¸ Usage
You can find an example using an `ff` CLI at [cmd/webff/main.go](cmd/webff/main.go), which you can run with:
```bash
go run cmd/webff/main.go
```You can find an example using a `cobra` CLI at [cmd/webcobra/main.go](cmd/webcobra/main.go), which you can run with:
```bash
go run cmd/webcobra/main.go
```## đ Resources
Resources used to create this project:
- [HTMX](https://htmx.org/)
- [Tailwind CSS](https://tailwindcss.com/)
- [templ](https://templ.guide) - An HTML templating language for Go## đ Support
Please give the repository a star â if you have found this code helpful.
For any questions, create an issue or ping me at [x.com/igolaizola](https://x.com/igolaizola).