diff --git a/.github/workflows/cd-badger.yml b/.github/workflows/cd-badger.yml index 2d6329bcb..626c91b6e 100644 --- a/.github/workflows/cd-badger.yml +++ b/.github/workflows/cd-badger.yml @@ -13,20 +13,15 @@ jobs: - uses: actions/checkout@v4 with: ref: '${{ github.event.inputs.releasetag }}' - - name: Get Go Version - run: | - #!/bin/bash - GOVERSION=$({ [ -f .go-version ] && cat .go-version; }) - echo "GOVERSION=$GOVERSION" >> $GITHUB_ENV - name: Set up Go uses: actions/setup-go@v5 with: - go-version: ${{ env.GOVERSION }} + go-version-file: go.mod - name: Set Badger Release Version run: | #!/bin/bash GIT_TAG_NAME='${{ github.event.inputs.releasetag }}' - if [[ "$GIT_TAG_NAME" == "v"* ]]; + if [[ "$GIT_TAG_NAME" == "v"* ]]; then echo "this is a release tag" else @@ -57,20 +52,15 @@ jobs: - uses: actions/checkout@v4 with: ref: '${{ github.event.inputs.releasetag }}' - - name: Get Go Version - run: | - #!/bin/bash - GOVERSION=$({ [ -f .go-version ] && cat .go-version; }) - echo "GOVERSION=$GOVERSION" >> $GITHUB_ENV - name: Set up Go uses: actions/setup-go@v5 with: - go-version: ${{ env.GOVERSION }} + go-version-file: go.mod - name: Set Badger Release Version run: | #!/bin/bash GIT_TAG_NAME='${{ github.event.inputs.releasetag }}' - if [[ "$GIT_TAG_NAME" == "v"* ]]; + if [[ "$GIT_TAG_NAME" == "v"* ]]; then echo "this is a release tag" else diff --git a/.github/workflows/ci-badger-bank-tests-nightly.yml b/.github/workflows/ci-badger-bank-tests-nightly.yml index 7ff04f746..0b3ee894b 100644 --- a/.github/workflows/ci-badger-bank-tests-nightly.yml +++ b/.github/workflows/ci-badger-bank-tests-nightly.yml @@ -17,15 +17,10 @@ jobs: runs-on: warp-ubuntu-latest-x64-4x steps: - uses: actions/checkout@v4 - - name: Get Go Version - run: | - #!/bin/bash - GOVERSION=$({ [ -f .go-version ] && cat .go-version; }) - echo "GOVERSION=$GOVERSION" >> $GITHUB_ENV - name: Setup Go uses: actions/setup-go@v5 with: - go-version: ${{ env.GOVERSION }} + go-version-file: go.mod - name: Install Dependencies run: make dependency - name: Install jemalloc diff --git a/.github/workflows/ci-badger-bank-tests.yml b/.github/workflows/ci-badger-bank-tests.yml index 9ff3dc7f3..87813b7fb 100644 --- a/.github/workflows/ci-badger-bank-tests.yml +++ b/.github/workflows/ci-badger-bank-tests.yml @@ -15,15 +15,10 @@ jobs: runs-on: warp-ubuntu-latest-x64-4x steps: - uses: actions/checkout@v4 - - name: Get Go Version - run: | - #!/bin/bash - GOVERSION=$({ [ -f .go-version ] && cat .go-version; }) - echo "GOVERSION=$GOVERSION" >> $GITHUB_ENV - name: Setup Go uses: actions/setup-go@v5 with: - go-version: ${{ env.GOVERSION }} + go-version-file: go.mod - name: Install Dependencies run: make dependency - name: Install jemalloc diff --git a/.github/workflows/ci-badger-tests-coverage.yml b/.github/workflows/ci-badger-tests-coverage.yml index c89448128..742540cff 100644 --- a/.github/workflows/ci-badger-tests-coverage.yml +++ b/.github/workflows/ci-badger-tests-coverage.yml @@ -17,15 +17,10 @@ jobs: - uses: actions/checkout@v4 # checkout merge commit with: ref: "refs/pull/${{ github.event.number }}/merge" - - name: Get Go Version - run: | - #!/bin/bash - GOVERSION=$({ [ -f .go-version ] && cat .go-version; }) - echo "GOVERSION=$GOVERSION" >> $GITHUB_ENV - name: Setup Go uses: actions/setup-go@v5 with: - go-version: ${{ env.GOVERSION }} + go-version-file: go.mod - name: Install Dependencies run: make dependency - name: Run Badger Tests diff --git a/.github/workflows/ci-badger-tests.yml b/.github/workflows/ci-badger-tests.yml index a1ad355b2..dfb41077c 100644 --- a/.github/workflows/ci-badger-tests.yml +++ b/.github/workflows/ci-badger-tests.yml @@ -15,15 +15,10 @@ jobs: runs-on: warp-ubuntu-latest-x64-4x steps: - uses: actions/checkout@v4 - - name: Get Go Version - run: | - #!/bin/bash - GOVERSION=$({ [ -f .go-version ] && cat .go-version; }) - echo "GOVERSION=$GOVERSION" >> $GITHUB_ENV - name: Setup Go uses: actions/setup-go@v5 with: - go-version: ${{ env.GOVERSION }} + go-version-file: go.mod - name: Install Dependencies run: make dependency - name: Run Badger Tests diff --git a/.github/workflows/ci-dgraph-tests.yml b/.github/workflows/ci-dgraph-tests.yml index 2d6f71382..a37cc4f02 100644 --- a/.github/workflows/ci-dgraph-tests.yml +++ b/.github/workflows/ci-dgraph-tests.yml @@ -18,15 +18,10 @@ jobs: with: repository: dgraph-io/dgraph ref: main - - name: Get Go Version - run: | - #!/bin/bash - GOVERSION=$({ [ -f .go-version ] && cat .go-version; }) - echo "GOVERSION=$GOVERSION" >> $GITHUB_ENV - name: Set up Go uses: actions/setup-go@v5 with: - go-version: ${{ env.GOVERSION }} + go-version-file: go.mod - name: Fetch latest Badger version run: | go get github.com/dgraph-io/badger/v4@main diff --git a/.github/workflows/ci-golang-lint.yml b/.github/workflows/ci-golang-lint.yml index fe3c0f684..d047278c0 100644 --- a/.github/workflows/ci-golang-lint.yml +++ b/.github/workflows/ci-golang-lint.yml @@ -16,15 +16,10 @@ jobs: runs-on: warp-ubuntu-latest-x64-4x steps: - uses: actions/checkout@v4 - - name: Get Go Version - run: | - #!/bin/bash - GOVERSION=$({ [ -f .go-version ] && cat .go-version; }) - echo "GOVERSION=$GOVERSION" >> $GITHUB_ENV - name: Setup Go uses: actions/setup-go@v5 with: - go-version: ${{ env.GOVERSION }} + go-version-file: go.mod - name: golang-lint uses: golangci/golangci-lint-action@v6.1.1 with: diff --git a/.go-version b/.go-version deleted file mode 100644 index 193d14030..000000000 --- a/.go-version +++ /dev/null @@ -1 +0,0 @@ -1.23 \ No newline at end of file diff --git a/README.md b/README.md index 3fd64d768..c0706e49b 100644 --- a/README.md +++ b/README.md @@ -62,7 +62,7 @@ For more details on our version naming schema please read [Choosing a version](# ## Getting Started ### Installing -To start using Badger, install Go 1.23 or above. Badger v3 and above needs go modules. From your project, run the following command +To start using Badger, install Go 1.21 or above. Badger v3 and above needs go modules. From your project, run the following command ```sh $ go get github.com/dgraph-io/badger/v4 diff --git a/go.mod b/go.mod index 9eb5abf6e..f088f794a 100644 --- a/go.mod +++ b/go.mod @@ -6,7 +6,7 @@ toolchain go1.23.2 require ( github.com/cespare/xxhash/v2 v2.3.0 - github.com/dgraph-io/ristretto/v2 v2.0.0-rc1 + github.com/dgraph-io/ristretto/v2 v2.0.0 github.com/dustin/go-humanize v1.0.1 github.com/gogo/protobuf v1.3.2 github.com/golang/protobuf v1.5.4 diff --git a/go.sum b/go.sum index be20234a7..43c599a37 100644 --- a/go.sum +++ b/go.sum @@ -9,8 +9,8 @@ github.com/cpuguy83/go-md2man/v2 v2.0.4/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46t github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/dgraph-io/ristretto/v2 v2.0.0-rc1 h1:hdTJGtatuthLoGQDw6OtjZEL0PBxgiHZLM1wkKxEOL4= -github.com/dgraph-io/ristretto/v2 v2.0.0-rc1/go.mod h1:FVFokF2dRqXyPyeMnK1YDy8Fc6aTe0IKgbcd03CYeEk= +github.com/dgraph-io/ristretto/v2 v2.0.0 h1:l0yiSOtlJvc0otkqyMaDNysg8E9/F/TYZwMbxscNOAQ= +github.com/dgraph-io/ristretto/v2 v2.0.0/go.mod h1:FVFokF2dRqXyPyeMnK1YDy8Fc6aTe0IKgbcd03CYeEk= github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13 h1:fAjc9m62+UWV/WAFKLNi6ZS0675eEUC9y3AlwSbQu1Y= github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13/go.mod h1:SqUrOPUnsFjfmXRMNPybcSiG0BgUW2AuFH8PAnS2iTw= github.com/dustin/go-humanize v1.0.1 h1:GzkhY7T5VNhEkwH0PVJgjz+fX1rhBrR7pRT3mDkpeCY=