Use python3 instead of python2

Change-Id: If75c8d42891efa87ca1922e2189027b077e37fd9
This commit is contained in:
Takashi Kajinami 2021-02-15 09:28:08 +09:00
parent 4961a6bf34
commit 7ea2e4f590

View File

@ -7,7 +7,7 @@
if [ -f Modulefile ]; then
MODULE=$(awk '/^name/ {print $NF}' Modulefile |tr -d \"\')
elif [ -f metadata.json ]; then
MODULE=$(python -c 'import json;print json.load(open("metadata.json"))["name"]')
MODULE=$(python3 -c 'import json;print(json.load(open("metadata.json"))["name"])')
fi
if [ -z "$MODULE" ]; then
echo "Module name not defined in Modulefile or metadata.json"