From 949bba78e8206d109f1bd9c97fd5a04d037c8334 Mon Sep 17 00:00:00 2001 From: Christopher Kaster Date: Tue, 16 Jul 2024 20:43:16 +0200 Subject: [PATCH] add AUR to goreleaser --- .github/workflows/build.yml | 5 +++-- .goreleaser.yml | 45 ++++++++++++++++++++++++++++--------- README.md | 4 ++++ 3 files changed, 41 insertions(+), 13 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 077f377..fe210a2 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -25,7 +25,7 @@ jobs: - name: Install Dependencies run: | go install github.com/mattn/goveralls@latest - curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v1.58.2 + curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v1.59.1 - name: Build & Test run: | make build @@ -47,7 +47,8 @@ jobs: with: distribution: goreleaser version: latest - args: release --rm-dist + args: release env: GITHUB_TOKEN: ${{ secrets.GH_TOKEN }} + AUR_KEY: ${{ secrets.AUR_KEY }} if: ${{ startsWith(github.ref, 'refs/tags/v') }} diff --git a/.goreleaser.yml b/.goreleaser.yml index dc97b10..18f89df 100644 --- a/.goreleaser.yml +++ b/.goreleaser.yml @@ -1,3 +1,5 @@ +version: 2 + builds: - main: ./cmd/crab/main.go ldflags: @@ -24,13 +26,34 @@ changelog: exclude: - '^docs:' - '^test:' + # Release + ## Github Releases release: github: owner: atomicptr name: crab draft: false + + +## AUR +aurs: + - name: crab-bin + homepage: &homepage "https://github.com/atomicptr/crab" + description: &description | + A versatile tool to crawl dozens of URLs from a given source, like a sitemap or an URL list. + private_key: "{{ .Env.AUR_KEY }}" + git_url: "ssh://aur@aur.archlinux.org/crab-bin.git" + provides: + - tmplr + commit_author: + name: Christopher Kaster + email: me@atomicptr.de + maintainers: &maintainers + - &maintainer "Christopher Kaster " + license: &license MIT + ## Homebrew brews: - name: crab @@ -38,19 +61,19 @@ brews: owner: atomicptr name: homebrew-tools directory: Formula - homepage: "https://github.com/atomicptr/crab" - description: | - A versatile tool to crawl dozens of URLs from a given source, like a sitemap or an URL list. + homepage: *homepage + description: *description + ## Scoop scoops: - name: crab repository: owner: atomicptr name: scoop-bucket - homepage: "https://github.com/atomicptr/crab" - description: | - A versatile tool to crawl dozens of URLs from a given source, like a sitemap or an URL list. - license: MIT + homepage: *homepage + description: *description + license: *license + ## Docker dockers: - dockerfile: Dockerfile @@ -59,14 +82,14 @@ dockers: - "atomicptr/crab:v{{.Major}}" - "atomicptr/crab:v{{.Major}}.{{.Minor}}" - "atomicptr/crab:{{.Tag}}" + ## NFPM (deb and rpm) nfpms: - package_name: crab vendor: atomicptr - maintainer: "Christopher Kaster " - homepage: "https://github.com/atomicptr/crab" - description: | - A versatile tool to crawl dozens of URLs from a given source, like a sitemap or an URL list. + maintainer: *maintainer + homepage: *homepage + description: *description license: MIT formats: - deb diff --git a/README.md b/README.md index 6287214..92b79b5 100644 --- a/README.md +++ b/README.md @@ -39,6 +39,10 @@ $ docker run --rm atomicptr/crab --help $ docker run --rm atomicptr/crab crawl:sitemap https://domain.com/sitemap.xml ``` +### Arch Linux + +[AUR](https://aur.archlinux.org/packages/crab-bin) + ### Homebrew ```bash