forked from ancore-org/ancore
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
94 lines (75 loc) · 4.95 KB
/
Copy pathMakefile
File metadata and controls
94 lines (75 loc) · 4.95 KB
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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
.PHONY: help install dev build test test-contracts lint lint-fix clean contracts-build contracts-test validate-env
# ──────────────────────────────────────────────────────────────────────────────
# HELP
# ──────────────────────────────────────────────────────────────────────────────
help:
@echo "Ancore Development Commands"
@echo ""
@echo "Setup:"
@echo " make install Install all dependencies"
@echo " make validate-env Validate service health endpoints"
@echo ""
@echo "Development:"
@echo " make dev Start development servers (TBD)"
@echo " make build Build all packages"
@echo ""
@echo "Testing:"
@echo " make test Run all tests"
@echo " make test-contracts Run Soroban contract tests"
@echo ""
@echo "Linting:"
@echo " make lint Lint all code"
@echo " make lint-fix Fix linting issues"
@echo ""
@echo "Contracts:"
@echo " make contracts-build Build Soroban contracts"
@echo " make contracts-test Run contract tests"
@echo ""
@echo "Cleanup:"
@echo " make clean Remove build artifacts"
# ──────────────────────────────────────────────────────────────────────────────
# SETUP
# ──────────────────────────────────────────────────────────────────────────────
install:
pnpm install
validate-env:
@bash scripts/dev/validate-env.sh
# ──────────────────────────────────────────────────────────────────────────────
# DEVELOPMENT
# ──────────────────────────────────────────────────────────────────────────────
dev:
@echo "Development server setup is in-progress"
@echo "Start services individually:"
@echo " - Indexer: pnpm --filter @ancore/indexer dev"
@echo " - Relayer: pnpm --filter @ancore/relayer dev"
@echo " - AI Agent: pnpm --filter @ancore/ai-agent dev"
build:
pnpm build
# ──────────────────────────────────────────────────────────────────────────────
# TESTING
# ──────────────────────────────────────────────────────────────────────────────
test:
pnpm test
test-contracts:
cd contracts && cargo test
# ──────────────────────────────────────────────────────────────────────────────
# LINTING
# ──────────────────────────────────────────────────────────────────────────────
lint:
pnpm lint
lint-fix:
pnpm lint -- --fix
# ──────────────────────────────────────────────────────────────────────────────
# CONTRACTS
# ──────────────────────────────────────────────────────────────────────────────
contracts-build:
pnpm contracts:build
contracts-test:
make test-contracts
# ──────────────────────────────────────────────────────────────────────────────
# CLEANUP
# ──────────────────────────────────────────────────────────────────────────────
clean:
pnpm clean
cd contracts && cargo clean || true
find . -type d -name node_modules -prune -exec rm -rf {} \; 2>/dev/null || true