-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #9 from antistatique/11x/drupal-10.2
drop tests support on Drupal <= 9.4 && add support of Drupal 10.2 & 11.0-dev
- Loading branch information
Showing
12 changed files
with
84 additions
and
86 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,15 +7,17 @@ https://github.com/antistatique/drupal-vercel-deploy/pulls | |
|
||
## 📦 Repositories | ||
|
||
Drupal repo | ||
|
||
``` | ||
$ git remote add drupal [email protected]:project/vercel_deploy.git | ||
``` | ||
|
||
Github repo | ||
``` | ||
$ git remote add drupal [email protected]:project/vercel_deploy.git | ||
``` | ||
|
||
Drupal repo | ||
``` | ||
$ git remote add github [email protected]:antistatique/drupal-vercel-deploy.git | ||
``` | ||
``` | ||
$ git remote add github [email protected]:antistatique/drupal-vercel-deploy.git | ||
``` | ||
|
||
## 🔧 Prerequisites | ||
|
||
|
@@ -25,31 +27,31 @@ globally on your environment: | |
* drush | ||
* Latest dev release of Drupal 9.x/10.x. | ||
* docker | ||
* docker-compose | ||
* docker compose | ||
|
||
### Project bootstrap | ||
|
||
Once run, you will be able to access to your fresh installed Drupal on | ||
`http://localhost:8888/`. | ||
|
||
docker-compose build --pull --build-arg BASE_IMAGE_TAG=9.3 drupal | ||
docker compose build --pull --build-arg BASE_IMAGE_TAG=10.2 drupal | ||
# (get a coffee, this will take some time...) | ||
docker-compose up -d drupal | ||
docker-compose exec -u www-data drupal drush site-install standard \ | ||
docker compose up -d drupal | ||
docker compose exec -u www-data drupal drush site-install standard \ | ||
--db-url="mysql://drupal:drupal@db/drupal" -y | ||
|
||
# You may be interesed by reseting the admin passowrd of your Docker and | ||
# install the module using those cmd. | ||
docker-compose exec drupal drush user:password admin admin | ||
docker-compose exec drupal drush en vercel_deploy -y | ||
docker compose exec drupal drush user:password admin admin | ||
docker compose exec drupal drush en vercel_deploy -y | ||
|
||
## 🏆 Tests | ||
|
||
We use the [Docker for Drupal Contrib images](https://hub.docker.com/r/wengerk/drupal-for-contrib) to run testing on our project. | ||
|
||
Run testing by stopping at first failure using the following command: | ||
|
||
docker-compose exec -u www-data drupal phpunit --group=vercel_deploy \ | ||
docker compose exec -u www-data drupal phpunit --group=vercel_deploy \ | ||
--no-coverage --stop-on-failure --configuration=/var/www/html/phpunit.xml | ||
|
||
## 🚔 Check Drupal coding standards & Drupal best practices | ||
|
@@ -70,7 +72,7 @@ The following Analyzer will be downloaded & installed as PHAR: | |
|
||
./scripts/hooks/post-commit | ||
# or run command on the container itself | ||
docker-compose exec drupal bash | ||
docker compose exec drupal bash | ||
|
||
#### Running Code Sniffer Drupal & DrupalPractice | ||
|
||
|
@@ -84,14 +86,14 @@ PHP_CodeSniffer is an essential development tool that ensures your code remains | |
clean and consistent. | ||
|
||
``` | ||
$ docker-compose exec drupal ./vendor/bin/phpcs \ | ||
$ docker compose exec drupal ./vendor/bin/phpcs \ | ||
./web/modules/contrib/vercel_deploy/ | ||
``` | ||
|
||
Automatically fix coding standards | ||
|
||
``` | ||
$ docker-compose exec drupal ./vendor/bin/phpcbf \ | ||
$ docker compose exec drupal ./vendor/bin/phpcbf \ | ||
./web/modules/contrib/vercel_deploy/ | ||
``` | ||
|
||
|
@@ -102,7 +104,7 @@ https://github.com/phpmd/phpmd | |
Detect overcomplicated expressions & Unused parameters, methods, properties. | ||
|
||
``` | ||
$ docker-compose exec drupal phpmd ./web/modules/contrib/vercel_deploy/ text \ | ||
$ docker compose exec drupal phpmd ./web/modules/contrib/vercel_deploy/ text \ | ||
./phpmd.xml \ | ||
--suffixes php,module,inc,install,test,profile,theme,css,info,txt \ | ||
--exclude *Test.php,*vendor/* | ||
|
@@ -115,7 +117,7 @@ https://github.com/sebastianbergmann/phpcpd | |
`phpcpd` is a Copy/Paste Detector (CPD) for PHP code. | ||
|
||
``` | ||
$ docker-compose exec drupal phpcpd ./web/modules/contrib/vercel_deploy/src \ | ||
$ docker compose exec drupal phpcpd ./web/modules/contrib/vercel_deploy/src \ | ||
--suffix .php --suffix .module --suffix .inc --suffix .install --suffix .test \ | ||
--suffix .profile --suffix .theme --suffix .css --suffix .info --suffix .txt \ | ||
--exclude *.md --exclude *.info.yml --exclude tests --exclude vendor/ | ||
|
@@ -128,7 +130,7 @@ https://github.com/wapmorgan/PhpDeprecationDetector | |
A scanner that checks compatibility of your code with PHP interpreter versions. | ||
|
||
``` | ||
$ docker-compose exec drupal phpdd ./web/modules/contrib/vercel_deploy/ \ | ||
$ docker compose exec drupal phpdd ./web/modules/contrib/vercel_deploy/ \ | ||
--file-extensions php,module,inc,install,test,profile,theme,info \ | ||
--exclude vendor | ||
``` | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -33,29 +33,16 @@ This module works on both Drupal 8, Drupal 9 & Drupal 10 ! | |
The Drupal 8, Drupal 9 & Drupal 10 version of this module requires nothing ! | ||
Feel free to use it. | ||
|
||
## Supporting organizations | ||
|
||
This project is sponsored by [Antistatique](https://www.antistatique.net), a Swiss Web Agency. | ||
Visit us at [www.antistatique.net](https://www.antistatique.net) or | ||
[Contact us](mailto:[email protected]). | ||
|
||
## Getting Started | ||
|
||
We highly recommend you to install the module using `composer`. | ||
|
||
<h2>Getting Started</h2> | ||
|
||
|
||
```bash | ||
$ composer require drupal/vercel_deploy | ||
``` | ||
|
||
You can also install it using the `drush` or `drupal console` cli. | ||
|
||
```bash | ||
$ drush dl vercel_deploy | ||
``` | ||
## Supporting organizations | ||
|
||
```bash | ||
$ drupal module:install vercel_deploy | ||
``` | ||
This project is sponsored by [Antistatique](https://www.antistatique.net), a Swiss Web Agency. | ||
Visit us at [www.antistatique.net](https://www.antistatique.net) or | ||
[Contact us](mailto:[email protected]). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,11 @@ | ||
echo "\n🚔 \033[0;32mRunning Code Sniffer Drupal & DrupalPractice for ./web/modules/contrib/vercel_deploy/ ...\033[0m" | ||
docker-compose exec drupal ./vendor/bin/phpcs ./web/modules/contrib/vercel_deploy/ | ||
docker compose exec drupal ./vendor/bin/phpcs ./web/modules/contrib/vercel_deploy/ | ||
|
||
echo "\n💩 \033[0;32mRunning PHP Mess Detector ...\033[0m" | ||
docker-compose exec drupal phpmd ./web/modules/contrib/vercel_deploy/ text ./phpmd.xml --suffixes php,module,inc,install,test,profile,theme,css,info,txt --exclude *Test.php,*vendor/* | ||
docker compose exec drupal phpmd ./web/modules/contrib/vercel_deploy/ text ./phpmd.xml --suffixes php,module,inc,install,test,profile,theme,css,info,txt --exclude *Test.php,*vendor/* | ||
|
||
echo "\n🛂 \033[0;32mRunning PHP Copy/Paste Detector ...\033[0m" | ||
docker-compose exec drupal phpcpd ./web/modules/contrib/vercel_deploy/src --suffix .php --suffix .module --suffix .inc --suffix .install --suffix .test --suffix .profile --suffix .theme --suffix .css --suffix .info --suffix .txt --exclude *.md --exclude *.info.yml --exclude tests --exclude vendor/ | ||
docker compose exec drupal phpcpd ./web/modules/contrib/vercel_deploy/src --suffix .php --suffix .module --suffix .inc --suffix .install --suffix .test --suffix .profile --suffix .theme --suffix .css --suffix .info --suffix .txt --exclude *.md --exclude *.info.yml --exclude tests --exclude vendor/ | ||
|
||
echo "\n🍫 \033[0;32mRunning PhpDeprecationDetector ...\033[0m" | ||
docker-compose exec drupal phpdd ./web/modules/contrib/vercel_deploy/ --file-extensions php,module,inc,install,test,profile,theme,info --exclude vendor | ||
docker compose exec drupal phpdd ./web/modules/contrib/vercel_deploy/ --file-extensions php,module,inc,install,test,profile,theme,info --exclude vendor |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters