-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile.win
More file actions
83 lines (68 loc) · 2.7 KB
/
Makefile.win
File metadata and controls
83 lines (68 loc) · 2.7 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
# lean-containers Makefile (Windows version)
# Provides convenient targets for development, testing, and release
.PHONY: help dev run release test clean build install
# Default target
help:
@echo lean-containers Makefile
@echo Available targets:
@echo dev Set up local development environment
@echo build Build the project
@echo test Run all tests
@echo run Run the application/CLI locally
@echo clean Clean build artifacts
@echo release-dry Build and test release artifacts (dry run)
@echo release Build and publish artifacts
@echo docker-build Build Docker image
@echo docker-run Run Docker container
@echo install Show installation instructions
dev:
@echo Setting up development environment...
@where lean >nul 2>&1 || (echo Installing Lean 4... && curl -sSf https://raw.githubusercontent.com/leanprover/lean4/master/elan-init.sh | sh)
@where lake >nul 2>&1 || echo Lake is included with Lean 4
lake update
lake build
@echo Development environment ready!
run:
@echo Running lean-containers...
lake build
lake env lean Main.lean
test:
@echo Running production tests...
lake build
lake env lean FinalProductionTest.lean
@echo All tests passed!
build:
@echo Building lean-containers...
lake build
clean:
@echo Cleaning build artifacts...
lake clean
install:
@echo To use lean-containers in your Lake project, add to your Lakefile:
@echo require lean-containers from git "https://github.com/fraware/lean-containers.git"
release-check:
@echo Validating release metadata consistency...
scripts\check-release-consistency.bat
release-dry:
@echo Dry run release process...
@echo 0. Validating release metadata...
make -f Makefile.win release-check
@echo 1. Building project...
lake build
@echo 2. Running tests...
lake env lean FinalProductionTest.lean
@where docker >nul 2>&1 && (echo 3. Testing Docker build... && docker build -t lean-containers:test . && echo 4. Testing Docker run... && docker run --rm lean-containers:test) || echo 3. Skipping Docker tests (Docker not found)
@echo Release dry run completed successfully!
release:
@echo Running release script...
@if exist scripts\release.bat (scripts\release.bat) else (echo Building release artifacts manually... && $(MAKE) build && $(MAKE) test && echo Building Docker image... && docker build --build-arg VERSION=dev -t ghcr.io/fraware/lean-containers:latest . && echo Release artifacts built successfully! && echo To publish: docker push ghcr.io/fraware/lean-containers:latest)
docker-build:
docker build -t lean-containers .
docker-run:
docker run --rm lean-containers
# CI/CD targets
ci-test:
lake build
lake env lean FinalProductionTest.lean
ci-build:
lake build