Merge pull request #1402 from MahdiBM/patch-1

Better error message when failing
pull/1414/head
liv 1 year ago committed by GitHub
commit 2f34370f2f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -141,7 +141,7 @@ git clone -q https://github.com/rust-lang/rustlings "$Path"
cd "$Path"
Version=$(curl -s https://api.github.com/repos/rust-lang/rustlings/releases/latest | ${PY} -c "import json,sys;obj=json.load(sys.stdin);print(obj['tag_name']);")
Version=$(curl -s https://api.github.com/repos/rust-lang/rustlings/releases/latest | ${PY} -c "import json,sys;obj=json.load(sys.stdin);print(obj['tag_name']) if 'tag_name' in obj else sys.exit(f\"Error: {obj['message']}\");")
CargoBin="${CARGO_HOME:-$HOME/.cargo}/bin"
if [[ -z ${Version} ]]

Loading…
Cancel
Save