diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e1f849a..376c3bd 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -16,7 +16,7 @@ jobs: - name: Install Go uses: actions/setup-go@v5 with: - go-version: "1.22.4" + go-version: "1.23.2" - name: Install Task uses: arduino/setup-task@v2 - name: Install dependencies diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 654ebe3..984e27c 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -1,3 +1,5 @@ +name: Release + on: workflow_dispatch: push: @@ -9,22 +11,16 @@ permissions: jobs: build: - name: GoReleaser Build + name: Release runs-on: ubuntu-latest - steps: - - name: Check out code into the Go module directory + - name: Checkout repo uses: actions/checkout@v4 - with: - fetch-depth: 0 - - - name: Set Up Go + - name: Install Go uses: actions/setup-go@v5 with: - go-version: "1.x" - id: go - - - name: run GoReleaser + go-version: "1.23.2" + - name: Release uses: goreleaser/goreleaser-action@v6 env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/.gitignore b/.gitignore index 7f1a824..ce3f162 100755 --- a/.gitignore +++ b/.gitignore @@ -22,3 +22,5 @@ dist/ .task/ # VS Code .vscode/ +# Binaries +up diff --git a/.goreleaser.yml b/.goreleaser.yml index 3788cf1..3e9f7e3 100644 --- a/.goreleaser.yml +++ b/.goreleaser.yml @@ -71,4 +71,3 @@ changelog: exclude: - "^docs:" - "^test:" - diff --git a/README.md b/README.md index 8397b56..b086d29 100755 --- a/README.md +++ b/README.md @@ -11,9 +11,14 @@ Troubleshoot problems with your Internet connection based on different ## Install -Binaries for all platforms are provided in the [releases](https://github.com/jesusprubio/up/releases) section. +### Binary Release -Direct install with go: +You can manually download a binary release for Linux, OSX, Windows or FreeBSD +from the [releases](https://github.com/jesusprubio/up/releases) page. + +### Go + +Please notice `latest` will install the dev version. ```sh go install -ldflags="-s -w" -v github.com/jesusprubio/up@latest @@ -28,10 +33,6 @@ against a randomly selected [public server](internal/servers.go) for each one. up ``` -## License - -This project is under the MIT License. See the [LICENSE](LICENSE) file for the full text. - [doc-img]: https://pkg.go.dev/badge/github.com/jesusprubio/up [doc]: https://pkg.go.dev/github.com/jesusprubio/up [ci-img]: https://github.com/jesusprubio/up/workflows/CI/badge.svg diff --git a/internal/probe_test.go b/internal/probe_test.go index 8c15993..64cb0a5 100644 --- a/internal/probe_test.go +++ b/internal/probe_test.go @@ -56,7 +56,7 @@ func TestProbeValidate(t *testing.T) { }) } -func TestProbeRun(t *testing.T) { +func TestProbeDo(t *testing.T) { t.Run("returns an error if the setup is invalid", func(t *testing.T) { p := Probe{} err := p.Do(context.Background())