|
1 | 1 | # How to contribute?
|
2 | 2 |
|
3 |
| -Fork and pull request! 😃 |
| 3 | +**Simple way**: Fork and pull request! 😃 |
4 | 4 |
|
5 |
| -NOTE: If the project does not have an issue for what you want to do, create an issue first. |
| 5 | +**NOTE**: If the project does not have an issue for what you want to do, create an issue first. |
6 | 6 |
|
7 | 7 | Feel free to submit [Github Issues](https://github.com/libresign/libresign/issues) or pull requests.
|
8 | 8 |
|
9 |
| -The documentation website is build from the docs folder with vuepress. |
| 9 | +But... follow the complete way: |
10 | 10 |
|
11 | 11 | ## To start front and backend development environment
|
12 | 12 |
|
13 |
| -```bash |
14 |
| -make serve |
15 |
| -``` |
| 13 | +* Start the Nextcloud development. |
| 14 | + > **NOTE**: I suggest to use this: https://github.com/LibreCodeCoop/nextcloud-docker-development/ only because is the environment that I use 😅. I also suggest to use https://github.com/juliushaertl/nextcloud-docker-dev but the setup will be a bit different of this tutorial. |
| 15 | +* Wait to be possible access `localhost` in your browser |
| 16 | +* Inside the folder of nextcloud environment (the folder that contains the project of previous step), go to `volumes/nextloud/apps-extra` clone the LibreSign repository |
| 17 | +* open bash in nextcloud container with `docker compose exec -u www-data nextcloud bash` |
| 18 | +* Inside bash of Nextcloud, go to folder `apps-extra/libresign` |
| 19 | +* Run the commands: |
| 20 | + ```bash |
| 21 | + # download composer dependencies |
| 22 | + composer install |
| 23 | + # download JS dependencies |
| 24 | + npm ci |
| 25 | + # build and watch JS changes |
| 26 | + npm run watch |
| 27 | + ``` |
| 28 | +* Now, access the `localhost` on your browser |
16 | 29 |
|
17 | 30 | ## To update API documentation
|
18 | 31 |
|
19 | 32 | [Repository of site and API documentation](https://github.com/libresign/libresign.github.io)
|
20 | 33 |
|
21 |
| -## To run PHPUnit |
| 34 | +## Executing tests |
| 35 | +### PHPUnit, Psalm, PHPCS,... |
22 | 36 |
|
23 |
| -```bash |
24 |
| -make test |
25 |
| -``` |
| 37 | +* Run all tests inside `bash` of `nextcloud` service |
26 | 38 |
|
27 | 39 | Read more in composer.json scripts section
|
| 40 | + |
| 41 | +### Behat |
| 42 | + |
| 43 | +* Access bash of `nextcloud` service |
| 44 | +* Go to folder `tests/integration` of Libresign app |
| 45 | +* Install dependencies: |
| 46 | + ```bash |
| 47 | + composer i |
| 48 | + ``` |
| 49 | +* Run tests: |
| 50 | + ```bash |
| 51 | + vendor/bin/behat |
| 52 | + ``` |
| 53 | + |
| 54 | +You also can run a specific scenario |
0 commit comments