mirror of
https://github.com/bytedance/deer-flow.git
synced 2026-04-25 11:18:22 +00:00
feat: add lint check of front-end (#534)
* feat: add lint check of front-end * add pnpm installation * add pnpm installation
This commit is contained in:
parent
0a02843666
commit
72f9c59195
35
.github/workflows/lint.yaml
vendored
35
.github/workflows/lint.yaml
vendored
@ -28,4 +28,37 @@ jobs:
|
|||||||
- name: Run linters
|
- name: Run linters
|
||||||
run: |
|
run: |
|
||||||
source .venv/bin/activate
|
source .venv/bin/activate
|
||||||
make lint
|
make lint
|
||||||
|
|
||||||
|
lint-frontend:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
|
||||||
|
- name: Setup Node.js
|
||||||
|
uses: actions/setup-node@v4
|
||||||
|
with:
|
||||||
|
node-version: '22'
|
||||||
|
|
||||||
|
- name: Install pnpm
|
||||||
|
run: npm install -g pnpm
|
||||||
|
|
||||||
|
- name: Install frontend dependencies
|
||||||
|
run: |
|
||||||
|
cd web
|
||||||
|
pnpm install --frozen-lockfile
|
||||||
|
|
||||||
|
- name: Run frontend linting
|
||||||
|
run: |
|
||||||
|
cd web
|
||||||
|
pnpm lint
|
||||||
|
|
||||||
|
- name: Check TypeScript types
|
||||||
|
run: |
|
||||||
|
cd web
|
||||||
|
pnpm typecheck
|
||||||
|
|
||||||
|
- name: Build frontend
|
||||||
|
run: |
|
||||||
|
cd web
|
||||||
|
pnpm build
|
||||||
8
Makefile
8
Makefile
@ -1,4 +1,4 @@
|
|||||||
.PHONY: help lint format install-dev serve test coverage langgraph-dev
|
.PHONY: help lint format install-dev serve test coverage langgraph-dev lint-frontend
|
||||||
|
|
||||||
help: ## Show this help message
|
help: ## Show this help message
|
||||||
@echo "Deer Flow - Available Make Targets:"
|
@echo "Deer Flow - Available Make Targets:"
|
||||||
@ -16,6 +16,12 @@ format: ## Format code using ruff
|
|||||||
lint: ## Lint and fix code using ruff
|
lint: ## Lint and fix code using ruff
|
||||||
uv run ruff check --fix --select I --config pyproject.toml .
|
uv run ruff check --fix --select I --config pyproject.toml .
|
||||||
|
|
||||||
|
lint-frontend: ## Lint frontend code and check build
|
||||||
|
cd web && pnpm install --frozen-lockfile
|
||||||
|
cd web && pnpm lint
|
||||||
|
cd web && pnpm typecheck
|
||||||
|
cd web && pnpm build
|
||||||
|
|
||||||
serve: ## Start development server with reload
|
serve: ## Start development server with reload
|
||||||
uv run server.py --reload
|
uv run server.py --reload
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user