1
0
mirror of https://github.com/esp8266/Arduino.git synced 2025-04-21 10:26:06 +03:00

fix CI: switch to python3 for pio (#7035)

This commit is contained in:
david gauchard 2020-01-25 22:55:34 +01:00 committed by GitHub
parent 158039e414
commit 6e37ee36f8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 10 additions and 9 deletions

View File

@ -24,11 +24,15 @@ jobs:
- name: "Platformio (1)" - name: "Platformio (1)"
stage: build stage: build
script: $TRAVIS_BUILD_DIR/tests/platformio.sh script: $TRAVIS_BUILD_DIR/tests/platformio.sh
install:
- sudo apt-get install python3-pip python3-setuptools
env: env:
- BUILD_PARITY=even - BUILD_PARITY=even
- name: "Platformio (2)" - name: "Platformio (2)"
stage: build stage: build
script: $TRAVIS_BUILD_DIR/tests/platformio.sh script: $TRAVIS_BUILD_DIR/tests/platformio.sh
install:
- sudo apt-get install python3-pip python3-setuptools
env: env:
- BUILD_PARITY=odd - BUILD_PARITY=odd

View File

@ -6,13 +6,13 @@ source "$TRAVIS_BUILD_DIR"/tests/common.sh
function install_platformio() function install_platformio()
{ {
pip install --user -U https://github.com/platformio/platformio/archive/develop.zip pip3 install --user -U https://github.com/platformio/platformio/archive/develop.zip
platformio platform install "https://github.com/platformio/platform-espressif8266.git#feature/stage" platformio platform install "https://github.com/platformio/platform-espressif8266.git#feature/stage"
sed -i 's/https:\/\/github\.com\/esp8266\/Arduino\.git/*/' ~/.platformio/platforms/espressif8266/platform.json sed -i 's/https:\/\/github\.com\/esp8266\/Arduino\.git/*/' ~/.platformio/platforms/espressif8266/platform.json
ln -s $TRAVIS_BUILD_DIR ~/.platformio/packages/framework-arduinoespressif8266 ln -sf $TRAVIS_BUILD_DIR ~/.platformio/packages/framework-arduinoespressif8266
# Install dependencies: # Install dependencies:
# - esp8266/examples/ConfigFile # - esp8266/examples/ConfigFile
pio lib install "ArduinoJson@^6.11.0" pio lib --global install "ArduinoJson@^6.11.0"
} }
function build_sketches_with_platformio() function build_sketches_with_platformio()

View File

@ -80,9 +80,6 @@ EOF
test -z "$BUILD_TYPE" || break test -z "$BUILD_TYPE" || break
done done
# use pip2 for python2 with python3 is around, platformio doesn't like it
cp tests/platformio.sh tests/platformio-custom.sh
sed -i 's,pip ,pip2 ,g' tests/platformio-custom.sh
git submodule update --init git submodule update --init
@ -117,11 +114,11 @@ elif [ "$BUILD_TYPE" = "build1_odd" ]; then
BUILD_PARITY=odd tests/build1.sh BUILD_PARITY=odd tests/build1.sh
elif [ "$BUILD_TYPE" = "platformio" ]; then elif [ "$BUILD_TYPE" = "platformio" ]; then
tests/platformio-custom.sh tests/platformio.sh
elif [ "$BUILD_TYPE" = "platformio_even" ]; then elif [ "$BUILD_TYPE" = "platformio_even" ]; then
BUILD_PARITY=even tests/platformio-custom.sh BUILD_PARITY=even tests/platformio.sh
elif [ "$BUILD_TYPE" = "platformio_odd" ]; then elif [ "$BUILD_TYPE" = "platformio_odd" ]; then
BUILD_PARITY=odd tests/platformio-custom.sh BUILD_PARITY=odd tests/platformio.sh
elif [ "$BUILD_TYPE" = host ]; then elif [ "$BUILD_TYPE" = host ]; then
tests/ci/host_test.sh tests/ci/host_test.sh