Use python3 instead of python2
Change-Id: If75c8d42891efa87ca1922e2189027b077e37fd9
This commit is contained in:
parent
4961a6bf34
commit
7ea2e4f590
@ -7,7 +7,7 @@
|
|||||||
if [ -f Modulefile ]; then
|
if [ -f Modulefile ]; then
|
||||||
MODULE=$(awk '/^name/ {print $NF}' Modulefile |tr -d \"\')
|
MODULE=$(awk '/^name/ {print $NF}' Modulefile |tr -d \"\')
|
||||||
elif [ -f metadata.json ]; then
|
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
|
fi
|
||||||
if [ -z "$MODULE" ]; then
|
if [ -z "$MODULE" ]; then
|
||||||
echo "Module name not defined in Modulefile or metadata.json"
|
echo "Module name not defined in Modulefile or metadata.json"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user