-
-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Also add contributing file to remember how to test the project 🧌
- Loading branch information
Showing
6 changed files
with
56 additions
and
12 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
# Contributing | ||
|
||
Contributions are welcome, of course. | ||
|
||
## Setting up an Environment | ||
|
||
You locally need: | ||
|
||
- PHP >= 7.4 (with `pdo_mysql` or `pdo_pgsql`) with [Composer](https://getcomposer.org/) installed | ||
- Node.js 20 (use `nvm install`) with Yarn installed | ||
- Docker (to run the database) | ||
|
||
Install deps: | ||
|
||
``` | ||
yarn | ||
composer i | ||
``` | ||
|
||
Then you can use Docker to launch the database (used for test or dev): | ||
|
||
``` | ||
docker run -d --name f43me-mysql -e MYSQL_ALLOW_EMPTY_PASSWORD=yes -p 3306:3306 mysql:latest | ||
``` | ||
|
||
## Running Tests | ||
|
||
You can setup the database and the project using: | ||
|
||
``` | ||
make prepare | ||
``` | ||
|
||
Once it's ok, launch tests: | ||
|
||
``` | ||
php bin/simple-phpunit -v | ||
``` | ||
|
||
## Linting | ||
|
||
Linter is used only on PHP files: | ||
|
||
``` | ||
php bin/php-cs-fixer fix | ||
php bin/phpstan analyse | ||
``` |
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