[Scoped] Update build script with no need define php 8.0 setup (#2449)

This commit is contained in:
Abdul Malik Ikhsan 2022-06-07 16:57:47 +07:00 committed by GitHub
parent cbbe410aff
commit 68b2dbfaf6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 6 deletions

View File

@ -52,8 +52,7 @@ jobs:
- run: composer install --no-dev --ansi
# early downgrade individual functions
- run: |
bin/rector process src/functions vendor/symfony/string/Resources/functions.php -c build/config/config-downgrade.php --ansi
- run: bin/rector process src/functions vendor/symfony/string/Resources/functions.php -c build/config/config-downgrade.php --ansi
# 1. copy files to $NESTED_DIRECTORY directory Exclude the scoped/nested directories to prevent rsync from copying in a loop
- run: rsync --exclude rector-build -av * rector-build --quiet

View File

@ -2,7 +2,7 @@
# usage:
#
# export PHP72_BIN_PATH=/opt/homebrew/Cellar/php@7.2/7.2.34_4/bin/php PHP80_BIN_PATH=/opt/homebrew/Cellar/php@8.0/8.0.19/bin/php && sh ./full_build.sh
# export PHP72_BIN_PATH=/opt/homebrew/Cellar/php@7.2/7.2.34_4/bin/php && sh ./full_build.sh
# see https://stackoverflow.com/questions/66644233/how-to-propagate-colors-from-bash-script-to-github-action?noredirect=1#comment117811853_66644233
export TERM=xterm-color
@ -23,8 +23,7 @@ composer install --ansi
composer install --no-dev --ansi
# early downgrade individual functions
bin/rector process src/functions -c build/config/config-downgrade.php --ansi --clear-cache
bin/rector process vendor/symfony/string/Resources/functions.php -c build/config/config-downgrade.php --ansi --clear-cache
bin/rector process src/functions vendor/symfony/string/Resources/functions.php -c build/config/config-downgrade.php --ansi
rsync --exclude rector-build -av * rector-build --quiet
@ -32,7 +31,6 @@ rm -rf rector-build/packages-tests rector-build/rules-tests rector-build/tests r
php -d memory_limit=-1 bin/rector process rector-build/bin rector-build/config rector-build/src rector-build/packages rector-build/rules rector-build/vendor --config build/config/config-downgrade.php --ansi --no-diffs
# Prefixing build only works on php <= 8.0, can be used locally with PHP80_BIN_PATH env
sh build/build-rector-scoped.sh rector-build rector-prefixed-downgraded
# verify syntax valid in php 7.2