mirror of
https://github.com/aptly-dev/aptly.git
synced 2026-04-20 19:38:39 +00:00
do not hardcode go version
This commit is contained in:
10
.github/workflows/ci.yml
vendored
10
.github/workflows/ci.yml
vendored
@@ -28,7 +28,6 @@ jobs:
|
|||||||
BOTO_CONFIG: /dev/null
|
BOTO_CONFIG: /dev/null
|
||||||
GO111MODULE: "on"
|
GO111MODULE: "on"
|
||||||
GOPROXY: "https://proxy.golang.org"
|
GOPROXY: "https://proxy.golang.org"
|
||||||
GOVER: '1.19'
|
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: "Install packages"
|
- name: "Install packages"
|
||||||
@@ -42,10 +41,15 @@ jobs:
|
|||||||
# fetch the whole repo for `git describe` to work
|
# fetch the whole repo for `git describe` to work
|
||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
|
|
||||||
|
- name: "Read go version from go.mod"
|
||||||
|
run: |
|
||||||
|
echo "GOVER=$(sed -n 's/^go \(.*\)/\1/p' go.mod)" >> $GITHUB_OUTPUT
|
||||||
|
id: goversion
|
||||||
|
|
||||||
- name: "Setup Go"
|
- name: "Setup Go"
|
||||||
uses: actions/setup-go@v3
|
uses: actions/setup-go@v3
|
||||||
with:
|
with:
|
||||||
go-version: ${{ env.GOVER }}
|
go-version: ${{ steps.goversion.outputs.GOVER }}
|
||||||
|
|
||||||
- name: "Get aptly version"
|
- name: "Get aptly version"
|
||||||
run: |
|
run: |
|
||||||
@@ -101,7 +105,7 @@ jobs:
|
|||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
name: ["Debian 12", "Debian 11", "Debian 10", "Ubuntu 22.04", "Ubuntu 20.04"]
|
name: ["Debian 12", "Debian 11", "Debian 10", "Ubuntu 24.04", "Ubuntu 22.04", "Ubuntu 20.04"]
|
||||||
include:
|
include:
|
||||||
- name: "Debian 12"
|
- name: "Debian 12"
|
||||||
suite: bookworm
|
suite: bookworm
|
||||||
|
|||||||
13
.github/workflows/golangci-lint.yml
vendored
13
.github/workflows/golangci-lint.yml
vendored
@@ -16,10 +16,17 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
- uses: actions/setup-go@v5
|
|
||||||
|
- name: "Read go version from go.mod"
|
||||||
|
run: |
|
||||||
|
echo "GOVER=$(sed -n 's/^go \(.*\)/\1/p' go.mod)" >> $GITHUB_OUTPUT
|
||||||
|
id: goversion
|
||||||
|
|
||||||
|
- name: "Setup Go"
|
||||||
|
uses: actions/setup-go@v3
|
||||||
with:
|
with:
|
||||||
go-version: '1.19'
|
go-version: ${{ steps.goversion.outputs.GOVER }}
|
||||||
cache: false
|
|
||||||
- name: Create VERSION file
|
- name: Create VERSION file
|
||||||
run: |
|
run: |
|
||||||
make -s version | tr -d '\n' > VERSION
|
make -s version | tr -d '\n' > VERSION
|
||||||
|
|||||||
Reference in New Issue
Block a user