-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into bugfix/multipart-form-variable-interpolation
- Loading branch information
Showing
228 changed files
with
7,485 additions
and
14,569 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,86 @@ | ||
name: Tests | ||
on: | ||
push: | ||
branches: [main] | ||
pull_request: | ||
branches: [main] | ||
jobs: | ||
unit-test: | ||
name: Unit Tests | ||
timeout-minutes: 60 | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-node@v3 | ||
with: | ||
node-version-file: '.nvmrc' | ||
- name: Install dependencies | ||
run: npm ci --legacy-peer-deps | ||
|
||
# build libraries | ||
- name: Build libraries | ||
run: | | ||
npm run build --workspace=packages/bruno-common | ||
npm run build --workspace=packages/bruno-query | ||
# test | ||
- name: Test Package bruno-query | ||
run: npm run test --workspace=packages/bruno-query | ||
- name: Test Package bruno-lang | ||
run: npm run test --workspace=packages/bruno-lang | ||
- name: Test Package bruno-schema | ||
run: npm run test --workspace=packages/bruno-schema | ||
- name: Test Package bruno-app | ||
run: npm run test --workspace=packages/bruno-app | ||
- name: Test Package bruno-js | ||
run: npm run test --workspace=packages/bruno-js | ||
- name: Test Package bruno-common | ||
run: npm run test --workspace=packages/bruno-common | ||
- name: Test Package bruno-cli | ||
run: npm run test --workspace=packages/bruno-cli | ||
- name: Test Package bruno-electron | ||
run: npm run test --workspace=packages/bruno-electron | ||
|
||
cli-test: | ||
name: CLI Tests | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-node@v3 | ||
with: | ||
node-version-file: '.nvmrc' | ||
|
||
- name: Install dependencies | ||
run: npm ci --legacy-peer-deps | ||
|
||
- name: Build Libraries | ||
run: | | ||
npm run build --workspace=packages/bruno-query | ||
npm run build --workspace=packages/bruno-common | ||
- name: Run tests | ||
run: | | ||
cd packages/bruno-tests/collection | ||
npm install | ||
node ../../bruno-cli/bin/bru.js run --env Prod --output junit.xml --format junit | ||
- name: Publish Test Report | ||
uses: dorny/test-reporter@v1 | ||
if: success() || failure() | ||
with: | ||
name: Test Report | ||
path: packages/bruno-tests/collection/junit.xml | ||
reporter: java-junit | ||
|
||
prettier: | ||
name: Prettier | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-node@v3 | ||
with: | ||
node-version-file: '.nvmrc' | ||
- name: Install dependencies | ||
run: npm ci --legacy-peer-deps | ||
- name: Run Prettier | ||
run: npm run test:prettier:web |
This file was deleted.
Oops, something went wrong.
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 |
---|---|---|
|
@@ -6,6 +6,8 @@ yarn.lock | |
pnpm-lock.yaml | ||
.pnp | ||
.pnp.js | ||
bun.lockb | ||
bun.lock | ||
|
||
# testing | ||
coverage | ||
|
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,87 @@ | ||
[English](/contributing.md) | [Українська](./contributing_ua.md) | [Русский](./contributing_ru.md) | [Türkçe](./contributing_tr.md) | [Deutsch](./contributing_de.md) | [Français](./contributing_fr.md) | [Português (BR)](./contributing_pt_br.md) | [বাংলা](./contributing_bn.md) | [Español](./contributing_es.md) | [Română](./contributing_ro.md) | [Polski](./contributing_pl.md) | **简体中文** | ||
|
||
## 让我们一起改进 Bruno! | ||
|
||
很高兴看到您考虑改进 Bruno。以下是获取 Bruno 并在您的电脑上运行它的规则和指南。 | ||
|
||
### 使用的技术 | ||
|
||
Bruno 基于 NextJs 和 React 构建。我们使用 Electron 来封装桌面版本。 | ||
|
||
我们使用的库包括: | ||
|
||
- CSS - Tailwind | ||
- 代码编辑器 - Codemirror | ||
- 状态管理 - Redux | ||
- 图标 - Tabler Icons | ||
- 表单 - formik | ||
- 模式验证 - Yup | ||
- 请求客户端 - axios | ||
- 文件系统监视器 - chokidar | ||
|
||
### 依赖项 | ||
|
||
您需要 [Node v18.x 或最新的 LTS 版本](https://nodejs.org/en/) 和 npm 8.x。我们在这个项目中也使用 npm 工作区(_npm workspaces_)。 | ||
|
||
## 开发 | ||
|
||
Bruno 是作为一个 _client lourd(重客户端)_ 应用程序开发的。您需要在一个终端中启动 nextjs 来加载应用程序,然后在另一个终端中启动 Electron 应用程序。 | ||
|
||
### 依赖项 | ||
|
||
- NodeJS v18 | ||
|
||
### 本地开发 | ||
|
||
```bash | ||
# 使用 node 版本 18 | ||
nvm use | ||
|
||
# 安装依赖项 | ||
npm i --legacy-peer-deps | ||
|
||
# 构建 graphql 文档 | ||
npm run build:graphql-docs | ||
|
||
# 构建 bruno 查询 | ||
npm run build:bruno-query | ||
|
||
# 启动 next(终端 1) | ||
npm run dev:web | ||
|
||
# 启动重客户端(终端 2) | ||
npm run dev:electron | ||
``` | ||
|
||
### 故障排除 | ||
|
||
在运行 npm install 时,您可能会遇到 Unsupported platform 错误。为了解决这个问题,请删除 node_modules 目录和 package-lock.json 文件,然后再次运行 npm install。这应该会安装运行应用程序所需的所有包。 | ||
|
||
```shell | ||
# 删除子目录中的 node_modules 目录 | ||
find ./ -type d -name "node_modules" -print0 | while read -d $'\0' dir; do | ||
rm -rf "$dir" | ||
done | ||
|
||
# 删除子目录中的 package-lock.json 文件 | ||
find . -type f -name "package-lock.json" -delete | ||
``` | ||
|
||
### 测试 | ||
|
||
```bash | ||
# bruno-schema | ||
npm test --workspace=packages/bruno-schema | ||
|
||
# bruno-lang | ||
npm test --workspace=packages/bruno-lang | ||
``` | ||
|
||
### 提交 Pull Request | ||
|
||
- 请保持 PR 精简并专注于单一目标 | ||
- 请遵循分支命名格式: | ||
- feature/[feature name]:该分支应包含特定功能 | ||
- 例如:feature/dark-mode | ||
- bugfix/[bug name]:该分支应仅包含特定 bug 的修复 | ||
- 例如:bugfix/bug-1 |
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
Oops, something went wrong.