diff --git a/.gitignore b/.gitignore index ed654fa..274b505 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ .DS_Store bin/ tmp/ +dist/ diff --git a/.goreleaser.yml b/.goreleaser.yml new file mode 100644 index 0000000..8f21974 --- /dev/null +++ b/.goreleaser.yml @@ -0,0 +1,31 @@ +# Goreleaser config file for bamstats +before: + hooks: + - go mod tidy +builds: +- env: + - CGO_ENABLED=0 + main: ./cmd/bamstats/main.go + ldflags: -s -w -X main.version={{ .Version }} -X main.commit={{ .ShortCommit }} -X main.date={{ .Date }} +archives: +- name_template: '{{ .ProjectName }}-{{ if ne .Version "dev" }}v{{ end }}{{ .Version }}-{{ .Os }}-{{ .Arch }}' + replacements: + 386: i386 + amd64: x86_64 +checksum: + name_template: '{{ .ProjectName }}_checksums.txt' +snapshot: + name_template: "dev" +changelog: + sort: desc + filters: + exclude: + - '^docs:' + - '^test:' + - 'goreleaser' + - '^Bump' +release: + github: + owner: guigolab + name: bamstats + name_template: "Version {{.Version}}" diff --git a/README.md b/README.md index 6c7a2d7..483803b 100644 --- a/README.md +++ b/README.md @@ -14,8 +14,8 @@ Use one of the following methods to install `Bamstats`. The easiest way is to download a pre-compiled binary from Github [releases](https://github.com/guigolab/bamstats/releases). Here is an example for installing the latest released version on Linux 64bit: ``` -export VERSION=0.3.2 OS=linux ARCH=amd64 BIN=/usr/local/bin -wget -O - https://github.com/guigolab/bamstats/releases/download/v${VERSION}/bamstats-v${VERSION}-${OS}-${ARCH}.tar.bz2 | tar xj --strip-components 3 -C ${BIN} +export VERSION=0.3.5 OS=linux ARCH=x86_64 BIN=/usr/local/bin +wget -O - https://github.com/guigolab/bamstats/releases/download/v${VERSION}/bamstats-v${VERSION}-${OS}-${ARCH}.tar.gz | tar xz -C ${BIN} bamstats ``` ### Install the latest version with go