Skip to content
This repository was archived by the owner on Mar 11, 2025. It is now read-only.

Commit bef1079

Browse files
yihaujoncinque
andauthored
chore: get solana version from different cargo files (#3962)
* chore: get solana version from different cargo files * Update patch.crates-io.sh Co-authored-by: Jon Cinque <[email protected]> * Update patch.crates-io.sh Co-authored-by: Jon Cinque <[email protected]> Co-authored-by: Jon Cinque <[email protected]>
1 parent 8caa543 commit bef1079

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

patch.crates-io.sh

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,9 @@ solana_dir=$(cd "$solana_dir" && pwd)
2424
cd "$(dirname "$0")"
2525

2626
source "$solana_dir"/scripts/read-cargo-variable.sh
27-
solana_ver=$(readCargoVariable version "$solana_dir"/sdk/Cargo.toml)
27+
# get version from Cargo.toml first. if it is empty, get it from other places.
28+
solana_ver="$(readCargoVariable version "$solana_dir"/Cargo.toml)"
29+
solana_ver=${solana_ver:-$(readCargoVariable version "$solana_dir"/sdk/Cargo.toml)}
2830

2931
crates_map=()
3032
crates_map+=("solana-account-decoder account-decoder")

0 commit comments

Comments
 (0)