forked from langflow-ai/langflow
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
52 lines (40 loc) · 1.14 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
.PHONY: all format lint build
all: help
coverage:
poetry run pytest --cov \
--cov-config=.coveragerc \
--cov-report xml \
--cov-report term-missing:skip-covered
test:
poetry run pytest tests
format:
poetry run black .
poetry run ruff --select I --fix .
lint:
poetry run mypy .
poetry run black . --check
poetry run ruff . --fix
install_frontend:
cd langflow/frontend && npm install
run_frontend:
cd langflow/frontend && npm start
run_backend:
poetry run uvicorn langflow_backend.main:app --port 5003 --reload
build_frontend:
cd langflow/frontend && CI='' npm run build
build:
make install_frontend
make build_frontend
cp -r langflow/frontend/build langflow/backend/langflow_backend/frontend
poetry build --format sdist
rm -rf langflow/backend/langflow_backend/frontend
publish:
make build
poetry publish
help:
@echo '----'
@echo 'format - run code formatters'
@echo 'lint - run linters'
@echo 'install_frontend - install the frontend dependencies'
@echo 'build_frontend - build the frontend static files'
@echo 'build - build the frontend static files and package the project'