File tree Expand file tree Collapse file tree 6 files changed +23
-10
lines changed Expand file tree Collapse file tree 6 files changed +23
-10
lines changed Original file line number Diff line number Diff line change
1
+ #! /usr/bin/env bash
2
+ set -Eeuo pipefail
3
+
4
+ # Search for rocksdb_version in makefile
5
+ rocksdb_version=$( grep " rocksdb_version" ./scripts/build/build.mk | cut -d' =' -f2)
6
+
7
+ if [[ -z " ${rocksdb_version} " ]]; then
8
+ echo " Error: rocksdb_version not found in ./scripts/build/build.mk" >&2
9
+ exit 1
10
+ else
11
+ echo " ROCKSDB_VERSION=${rocksdb_version} " >> " ${GITHUB_ENV} "
12
+ fi
Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ sudo apt update && sudo apt-get install -y libsnappy-dev zlib1g-dev libbz2-dev l
12
12
# Clone RocksDB repository
13
13
git clone https://github.com/facebook/rocksdb.git /home/runner/rocksdb
14
14
cd /home/runner/rocksdb || exit 1
15
- git checkout " v ${ROCKSDB_VERSION} "
15
+ git checkout " ${ROCKSDB_VERSION} "
16
16
17
17
# Build shared library
18
18
sudo make -j " $( nproc --all) " shared_lib
Original file line number Diff line number Diff line change @@ -13,9 +13,6 @@ concurrency:
13
13
group : ci-${{ github.ref }}-build
14
14
cancel-in-progress : true
15
15
16
- env :
17
- ROCKSDB_VERSION : 9.6.1
18
-
19
16
jobs :
20
17
build :
21
18
runs-on : ubuntu-latest
28
25
with :
29
26
go-version : " 1.23"
30
27
check-latest : true
28
+ - name : Get rocksdb version
29
+ run : ./.github/scripts/get-rocksdb-version.sh
31
30
- name : Fix permissions for cache
32
31
run : sudo chown $(whoami) /usr/local/lib /usr/local/include
33
32
- name : Restore rocksdb libraries cache
Original file line number Diff line number Diff line change 9
9
permissions :
10
10
contents : read
11
11
12
- env :
13
- ROCKSDB_VERSION : 9.6.1
14
-
15
12
jobs :
16
13
golangci :
17
14
name : golangci-lint
30
27
Makefile
31
28
**/Makefile
32
29
.golangci.yml
30
+ - name : Get rocksdb version
31
+ run : ./.github/scripts/get-rocksdb-version.sh
33
32
- name : Fix permissions for cache
34
33
run : sudo chown $(whoami) /usr/local/lib /usr/local/include
35
34
- name : Restore rocksdb libraries cache
Original file line number Diff line number Diff line change @@ -13,9 +13,6 @@ concurrency:
13
13
group : ci-${{ github.ref }}-tests
14
14
cancel-in-progress : true
15
15
16
- env :
17
- ROCKSDB_VERSION : 9.6.1
18
-
19
16
jobs :
20
17
split-test-files :
21
18
runs-on : ubuntu-latest
@@ -790,6 +787,8 @@ jobs:
790
787
store/**/*.go
791
788
store/go.mod
792
789
store/go.sum
790
+ - name : Get rocksdb version
791
+ run : ./.github/scripts/get-rocksdb-version.sh
793
792
- name : Fix permissions for cache
794
793
run : sudo chown $(whoami) /usr/local/lib /usr/local/include
795
794
- name : Restore rocksdb libraries cache
@@ -845,6 +844,8 @@ jobs:
845
844
store/v2/**/*.go
846
845
store/v2/go.mod
847
846
store/v2/go.sum
847
+ - name : Get rocksdb version
848
+ run : ./.github/scripts/get-rocksdb-version.sh
848
849
- name : Fix permissions for cache
849
850
run : sudo chown $(whoami) /usr/local/lib /usr/local/include
850
851
- name : Restore rocksdb libraries cache
Original file line number Diff line number Diff line change @@ -12,6 +12,8 @@ HTTPS_GIT := https://github.com/cosmos/cosmos-sdk.git
12
12
DOCKER := $(shell which docker)
13
13
PROJECT_NAME = $(shell git remote get-url origin | xargs basename -s .git)
14
14
15
+ rocksdb_version =v9.6.1
16
+
15
17
ifeq ($(findstring .,$(VERSION ) ) ,)
16
18
VERSION := 0.0.0
17
19
endif
You can’t perform that action at this time.
0 commit comments