|
1 | | -.PHONY: help build test test-unit test-e2e lint clean coverage coverage-html serve-docs |
| 1 | +.PHONY: help build build-all build-gitlab build-github build-bitbucket build-devops build-gitea test test-unit test-e2e lint clean coverage coverage-html serve-docs |
2 | 2 |
|
3 | 3 | # Default target |
4 | 4 | help: |
5 | 5 | @echo "Pipeleak Makefile" |
6 | 6 | @echo "" |
7 | 7 | @echo "Available targets:" |
8 | | - @echo " make build - Build the pipeleak binary" |
9 | | - @echo " make test - Run all tests (unit + e2e)" |
10 | | - @echo " make test-unit - Run unit tests only" |
11 | | - @echo " make test-e2e - Run e2e tests (builds binary first)" |
12 | | - @echo " make coverage - Generate test coverage report" |
13 | | - @echo " make coverage-html - Generate and open HTML coverage report" |
14 | | - @echo " make lint - Run golangci-lint" |
15 | | - @echo " make serve-docs - Generate and serve CLI documentation" |
16 | | - @echo " make clean - Remove built artifacts" |
17 | | - |
18 | | -# Build the pipeleak binary |
| 8 | + @echo " make build - Build the main pipeleak binary" |
| 9 | + @echo " make build-all - Build all binaries (main + platform-specific)" |
| 10 | + @echo " make build-gitlab - Build GitLab-specific binary" |
| 11 | + @echo " make build-github - Build GitHub-specific binary" |
| 12 | + @echo " make build-bitbucket - Build BitBucket-specific binary" |
| 13 | + @echo " make build-devops - Build Azure DevOps-specific binary" |
| 14 | + @echo " make build-gitea - Build Gitea-specific binary" |
| 15 | + @echo " make test - Run all tests (unit + e2e)" |
| 16 | + @echo " make test-unit - Run unit tests only" |
| 17 | + @echo " make test-e2e - Run e2e tests (builds binary first)" |
| 18 | + @echo " make coverage - Generate test coverage report" |
| 19 | + @echo " make coverage-html - Generate and open HTML coverage report" |
| 20 | + @echo " make lint - Run golangci-lint" |
| 21 | + @echo " make serve-docs - Generate and serve CLI documentation" |
| 22 | + @echo " make clean - Remove built artifacts" |
| 23 | + |
| 24 | +# Build the main pipeleak binary |
19 | 25 | build: |
20 | 26 | @echo "Building pipeleak..." |
21 | 27 | go build -o pipeleak ./cmd/pipeleak |
22 | 28 |
|
| 29 | +# Build GitLab-specific binary |
| 30 | +build-gitlab: |
| 31 | + @echo "Building pipeleak-gitlab..." |
| 32 | + go build -o pipeleak-gitlab ./cmd/pipeleak-gitlab |
| 33 | + |
| 34 | +# Build GitHub-specific binary |
| 35 | +build-github: |
| 36 | + @echo "Building pipeleak-github..." |
| 37 | + go build -o pipeleak-github ./cmd/pipeleak-github |
| 38 | + |
| 39 | +# Build BitBucket-specific binary |
| 40 | +build-bitbucket: |
| 41 | + @echo "Building pipeleak-bitbucket..." |
| 42 | + go build -o pipeleak-bitbucket ./cmd/pipeleak-bitbucket |
| 43 | + |
| 44 | +# Build Azure DevOps-specific binary |
| 45 | +build-devops: |
| 46 | + @echo "Building pipeleak-devops..." |
| 47 | + go build -o pipeleak-devops ./cmd/pipeleak-devops |
| 48 | + |
| 49 | +# Build Gitea-specific binary |
| 50 | +build-gitea: |
| 51 | + @echo "Building pipeleak-gitea..." |
| 52 | + go build -o pipeleak-gitea ./cmd/pipeleak-gitea |
| 53 | + |
| 54 | +# Build all binaries |
| 55 | +build-all: build build-gitlab build-github build-bitbucket build-devops build-gitea |
| 56 | + @echo "All binaries built successfully" |
| 57 | + |
23 | 58 | # Run all tests |
24 | 59 | test: test-unit test-e2e |
25 | 60 |
|
@@ -96,4 +131,9 @@ serve-docs: build |
96 | 131 | clean: |
97 | 132 | @echo "Cleaning up..." |
98 | 133 | rm -f pipeleak pipeleak.exe coverage.out coverage.html |
| 134 | + rm -f pipeleak-gitlab pipeleak-gitlab.exe |
| 135 | + rm -f pipeleak-github pipeleak-github.exe |
| 136 | + rm -f pipeleak-bitbucket pipeleak-bitbucket.exe |
| 137 | + rm -f pipeleak-devops pipeleak-devops.exe |
| 138 | + rm -f pipeleak-gitea pipeleak-gitea.exe |
99 | 139 | go clean -cache -testcache |
0 commit comments