Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/draganm/gorefresh
https://github.com/draganm/gorefresh
Last synced: about 2 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/draganm/gorefresh
- Owner: draganm
- License: mit
- Created: 2024-04-15T20:31:56.000Z (9 months ago)
- Default Branch: main
- Last Pushed: 2024-05-09T16:16:20.000Z (8 months ago)
- Last Synced: 2024-06-19T11:20:48.905Z (7 months ago)
- Language: Go
- Size: 13.7 KB
- Stars: 3
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
README
# gorefresh - the missing `go run --watch`
[![Go Report Card](https://goreportcard.com/badge/github.com/draganm/gorefresh)](https://goreportcard.com/report/github.com/draganm/gorefresh)
[![GoDoc](https://pkg.go.dev/badge/github.com/draganm/gorefresh)](https://pkg.go.dev/github.com/draganm/gorefresh)
![License](https://img.shields.io/github/license/draganm/gorefresh)Are you tired of running go run every time you make a change to your Go code? Do you want to run your Go code as soon as you save it? gorefresh is a simple tool that watches your Go files and runs them whenever they change.
I built this because I was tired of configuring [reflex](https://github.com/cespare/reflex) or [air](https://github.com/cosmtrek/air), especially when using embedded files. I wanted a simple tool that would just work.## 🌟 Key Features
- Automatically discovers dependencies (Go, cgo and embedded files) based on the main module directory.
- Builds and restarts only if the dependencies have changed (see [gosha](https://github.com/draganm/gosha)).
- Supports program arguments.## 📘 Usage
```bash
gorefresh -- [ program arguments ]
```## 📥 Installation
Install the CLI tool using `go get`:
```bash
go install github.com/draganm/gorefresh
```Or with Nix:
```bash
nix run github:draganm/gorefresh
```## Future work
- Support for build arguments
- Restart only if the build outputs change## 👥 Contributing
Contributions are welcome! Feel free to submit issues for bug reports, feature requests, or even pull requests.
## 📜 License
This project is licensed under the MIT License.