refs #5739 feat: init.sh refactor(readme): add new commands
gitea/salix/pipeline/head There was a failure building this commit Details

This commit is contained in:
Alex Moreno 2024-01-16 09:54:04 +01:00
parent 9bb0261897
commit aefef1bfa6
2 changed files with 38 additions and 13 deletions

View File

@ -8,44 +8,69 @@ Salix is also the scientific name of a beautifull tree! :)
Required applications.
* Node.js
* Docker
* Git
You will need to install globally the following items.
```
$ sudo npm install -g jest gulp-cli
```
Optional.
- NodeJS
## Directory structure recommendation
- /Salix
- /back ← this project
- /front ← salix-front project
## Installing dependencies and launching
Pull from repository.
```sh
$ git clone [url] [directory]
```
Run this commands on project root directory to install Node dependencies.
```
$ npm install
$ gulp install
```sh
$ sh init.sh
```
Launch application in developer environment.
```sh
$ docker compose -f docker-compose.local.yml up
```
$ gulp
With NodeJS
```sh
$ npm run start
```
Manually reset fixtures.
```
$ gulp docker
```sh
$ docker compose -f docker-compose.local.yml up --build
```
With NodeJS
```sh
$ npm run restart
```
## Running the unit tests
For client-side unit tests run from project's root.
```sh
$ sh runTestFront.sh
```
With NodeJS
```sh
$ npm run test:front
```
For server-side unit tests run from project's root.
```sh
$ sh runTestBack.sh
```
With NodeJS
```sh
$ npm run test:back
```

View File

@ -2,6 +2,6 @@ sudo docker run --rm -it \
-w /salix \
-v $PWD/../salix:/salix \
node:20-bullseye \
npm i -g gulp-cli \
npm i \
npm i -g gulp-cli && \
npm i && \
gulp i