Skip to content

Commit

Permalink
Update jas_realpath to use python3 for python3-only environment
Browse files Browse the repository at this point in the history
  • Loading branch information
hydrogencl authored Nov 30, 2023
1 parent 917f770 commit a97dc2b
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion build/jas_realpath
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,8 @@ if [ $# -ne 1 ]; then
fi

path="$1"
python -c 'import os,sys;print(os.path.realpath(sys.argv[1]))' "$path"
if ! command -v python &> /dev/null; then
python3 -c 'import os,sys;print(os.path.realpath(sys.argv[1]))' "$path"
else
python -c 'import os,sys;print(os.path.realpath(sys.argv[1]))' "$path"
fi

0 comments on commit a97dc2b

Please sign in to comment.