2023-10-25 18:38:50 +02:00
**English** | [Українська ](/docs/development_ua.md ) | [Русский ](/docs/development_ru.md ) | [Deutsch ](/docs/development_de.md ) | [Français ](/docs/development_fr.md )
2023-10-05 21:47:14 +02:00
2023-02-15 21:29:07 +01:00
## Development
2022-10-19 16:04:42 +02:00
2023-09-28 19:16:41 +02:00
Bruno is being developed as a desktop app. You need to load the app by running the nextjs app in one terminal and then run the electron app in another terminal.
2023-01-21 22:08:59 +01:00
### Dependencies
2023-09-30 06:19:02 +02:00
- NodeJS v18
2023-01-21 22:08:59 +01:00
2023-02-15 21:28:11 +01:00
### Local Development
2023-01-21 22:08:59 +01:00
2022-10-14 18:21:59 +02:00
```bash
2023-01-21 22:08:59 +01:00
# use nodejs 18 version
nvm use
2022-10-14 18:21:59 +02:00
# install deps
2023-02-15 21:26:38 +01:00
npm i --legacy-peer-deps
# build graphql docs
npm run build:graphql-docs
2022-10-14 18:21:59 +02:00
2023-03-19 11:11:18 +01:00
# build bruno query
2023-03-19 20:14:52 +01:00
npm run build:bruno-query
2023-03-19 11:11:18 +01:00
2023-02-15 21:28:11 +01:00
# run next app (terminal 1)
2023-02-16 20:22:35 +01:00
npm run dev:web
2022-10-15 16:44:43 +02:00
2023-02-15 21:28:11 +01:00
# run electron app (terminal 2)
2023-02-16 20:22:35 +01:00
npm run dev:electron
2022-10-14 18:21:59 +02:00
```
2023-02-15 21:29:07 +01:00
### Troubleshooting
2022-10-19 16:04:42 +02:00
You might encounter a `Unsupported platform` error when you run `npm install` . To fix this, you will need to delete `node_modules` and `package-lock.json` and run `npm install` . This should install all the necessary packages needed to run the app.
2023-02-22 19:08:48 +01:00
```shell
# Delete node_modules in sub-directories
find ./ -type d -name "node_modules" -print0 | while read -d $'\0' dir; do
rm -rf "$dir"
done
# Delete package-lock in sub-directories
find . -type f -name "package-lock.json" -delete
```
2023-02-15 21:29:07 +01:00
### Testing
2022-10-19 16:04:42 +02:00
2022-10-14 18:21:59 +02:00
```bash
# bruno-schema
npm test --workspace=packages/bruno-schema
2023-01-21 22:08:59 +01:00
# bruno-lang
2023-02-16 20:22:35 +01:00
npm test --workspace=packages/bruno-lang
2022-10-19 16:04:42 +02:00
```