mirror of
https://github.com/actions/runner-images.git
synced 2025-12-13 12:48:18 +00:00
Add pypy and pypy3 to PATH during tools cache download
This commit is contained in:
@@ -37,6 +37,15 @@ done;
|
|||||||
pypys=$(ls $AGENT_TOOLSDIRECTORY/PyPy)
|
pypys=$(ls $AGENT_TOOLSDIRECTORY/PyPy)
|
||||||
for pypy in $pypys; do
|
for pypy in $pypys; do
|
||||||
DocumentInstalledItemIndent "PyPy $pypy"
|
DocumentInstalledItemIndent "PyPy $pypy"
|
||||||
|
|
||||||
|
# Add symlinks for pypy2 and pypy3 to usr/local/bin, there should only be 2 versions of PyPy in the tools cache that is downloaded
|
||||||
|
if [ ${pypy:0:1} -eq "3" ] ; then
|
||||||
|
# add pypy 3.X to PATH
|
||||||
|
ln -s $AGENT_TOOLSDIRECTORY/PyPy/$pypy/x64/bin/pypy3 /usr/local/bin/pypy3
|
||||||
|
else
|
||||||
|
# add pypy 2.X to PATH
|
||||||
|
ln -s $AGENT_TOOLSDIRECTORY/PyPy/$pypy/x64/bin/pypy /usr/local/bin/pypy
|
||||||
|
fi
|
||||||
done;
|
done;
|
||||||
|
|
||||||
DocumentInstalledItem "Ruby (available through the [Use Ruby Version](https://go.microsoft.com/fwlink/?linkid=2005989) task)"
|
DocumentInstalledItem "Ruby (available through the [Use Ruby Version](https://go.microsoft.com/fwlink/?linkid=2005989) task)"
|
||||||
|
|||||||
@@ -37,6 +37,15 @@ done;
|
|||||||
pypys=$(ls $AGENT_TOOLSDIRECTORY/PyPy)
|
pypys=$(ls $AGENT_TOOLSDIRECTORY/PyPy)
|
||||||
for pypy in $pypys; do
|
for pypy in $pypys; do
|
||||||
DocumentInstalledItemIndent "PyPy $pypy"
|
DocumentInstalledItemIndent "PyPy $pypy"
|
||||||
|
|
||||||
|
# Add symlinks for pypy2 and pypy3 to usr/local/bin, there should only be 2 versions of PyPy in the tools cache that is downloaded
|
||||||
|
if [ ${pypy:0:1} -eq "3" ] ; then
|
||||||
|
# add pypy 3.X to PATH
|
||||||
|
ln -s $AGENT_TOOLSDIRECTORY/PyPy/$pypy/x64/bin/pypy3 /usr/local/bin/pypy3
|
||||||
|
else
|
||||||
|
# add pypy 2.X to PATH
|
||||||
|
ln -s $AGENT_TOOLSDIRECTORY/PyPy/$pypy/x64/bin/pypy /usr/local/bin/pypy
|
||||||
|
fi
|
||||||
done;
|
done;
|
||||||
|
|
||||||
DocumentInstalledItem "Ruby (available through the [Use Ruby Version](https://go.microsoft.com/fwlink/?linkid=2005989) task)"
|
DocumentInstalledItem "Ruby (available through the [Use Ruby Version](https://go.microsoft.com/fwlink/?linkid=2005989) task)"
|
||||||
|
|||||||
@@ -12,7 +12,7 @@ apt-get install -y --no-install-recommends python python-dev python-pip python3
|
|||||||
|
|
||||||
# Run tests to determine that the software installed as expected
|
# Run tests to determine that the software installed as expected
|
||||||
echo "Testing to make sure that script performed as expected, and basic scenarios work"
|
echo "Testing to make sure that script performed as expected, and basic scenarios work"
|
||||||
for cmd in python python3; do
|
for cmd in python pip python3 pip3; do
|
||||||
if ! command -v $cmd; then
|
if ! command -v $cmd; then
|
||||||
echo "$cmd was not installed or not found on PATH"
|
echo "$cmd was not installed or not found on PATH"
|
||||||
exit 1
|
exit 1
|
||||||
|
|||||||
Reference in New Issue
Block a user