From b1ad11db9308f51c5ff534e55543ce83a991a542 Mon Sep 17 00:00:00 2001 From: Kirtan Gajjar <8456197+kirtangajjar@users.noreply.github.com> Date: Thu, 4 Jul 2024 21:14:53 +0530 Subject: [PATCH] Convert all npm run to npx --- tests/bin/initialize.sh | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/tests/bin/initialize.sh b/tests/bin/initialize.sh index 4d4ab192b..4d2e7d920 100755 --- a/tests/bin/initialize.sh +++ b/tests/bin/initialize.sh @@ -2,20 +2,20 @@ set -e npx wp-env run tests-wordpress chmod -c ugo+w /var/www/html -npm run env run tests-cli wp rewrite structure '/%postname%/' --hard +npx wp-env run tests-cli wp rewrite structure '/%postname%/' --hard status=0 -npm run env run tests-cli wp site list || status=$? +npx wp-env run tests-cli wp site list || status=$? if [ $status -eq 0 ] then echo "Multisite already initialized" else echo "Converting to multisite" - npm run env run tests-cli wp core multisite-convert --title='Distributor Multisite' - npm run env run tests-cli wp user create second 'second@admin.local' --user_pass=password --role=administrator - npm run env run tests-cli wp site create --slug=second --title='Second Site' --email='second@admin.local' - npm run env run tests-cli wp theme enable twentytwentyone --activate - npm run env run tests-cli wp theme enable twentytwentyone --url=localhost/second --activate - npm run env run tests-cli cp wp-content/plugins/distributor/tests/cypress/.htaccess .htaccess + npx wp-env run tests-cli wp core multisite-convert --title='Distributor Multisite' + npx wp-env run tests-cli wp user create second 'second@admin.local' --user_pass=password --role=administrator + npx wp-env run tests-cli wp site create --slug=second --title='Second Site' --email='second@admin.local' + npx wp-env run tests-cli wp theme enable twentytwentyone --activate + npx wp-env run tests-cli wp theme enable twentytwentyone --url=localhost/second --activate + npx wp-env run tests-cli cp wp-content/plugins/distributor/tests/cypress/.htaccess .htaccess fi