Skip to content

Commit

Permalink
chore: skip spl downstream project test when the used version too hig…
Browse files Browse the repository at this point in the history
…h (backport #27326) (#27357)

chore: skip spl downstream project test when the used version too high (#27326)

* skip spl build when solana version too high

* lint

(cherry picked from commit 3b01517)

Co-authored-by: Yihau Chen <a122092487@gmail.com>
  • Loading branch information
mergify[bot] and yihau authored Aug 24, 2022
1 parent a0f82d1 commit 08b003f
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion scripts/build-downstream-projects.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
set -e
cd "$(dirname "$0")"/..
source ci/_
source ci/semver_bash/semver.sh
source scripts/patch-crates.sh
source scripts/read-cargo-variable.sh

Expand Down Expand Up @@ -50,12 +51,19 @@ spl() {
memo/program
name-service/program
stake-pool/program
)
)
set -x
rm -rf spl
git clone https://github.com/solana-labs/solana-program-library.git spl
cd spl

project_used_solana_version=$(sed -nE 's/solana-sdk = \"[>=<~]*(.*)\"/\1/p' <"token/program/Cargo.toml")
echo "used solana version: $project_used_solana_version"
if semverGT "$project_used_solana_version" "$solana_ver"; then
echo "skip"
return
fi

./patch.crates-io.sh "$solana_dir"

for program in "${PROGRAMS[@]}"; do
Expand Down

0 comments on commit 08b003f

Please sign in to comment.