Cut isn't needed here

This commit is contained in:
krisdoodle45 2021-10-06 17:12:41 +02:00 committed by GitHub
parent a3e76f32b8
commit 9ad912fe4e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -229,7 +229,7 @@ continentcode=$(echo "$chosen" | sed "s/:.*//")
radarcode=$(echo "$chosen" | sed "s/..: // ; s/:.*//") radarcode=$(echo "$chosen" | sed "s/..: // ; s/:.*//")
# Sanity check of selection and ensure user did not escape. # Sanity check of selection and ensure user did not escape.
echo "$radarcode" | grep -q "^[A-Z]\+$" && printf "$continentcode,$radarcode" | cut -d' ' -f1 > "$radarloc" ;} echo "$radarcode" | grep -q "^[A-Z]\+$" && printf "%s,%s\\n" "$continentcode" "$radarcode" > "$radarloc" ;}
getdoppler() { getdoppler() {
cont="$(cat "$radarloc" | sed "s/,.*//")" cont="$(cat "$radarloc" | sed "s/,.*//")"