-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
48 lines (38 loc) · 1.27 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
.PHONY: all start stop user main mod clear help
all: mod user main
# Start the environment of online judge
start:
docker-compose up -d
# Stop the environment of online judge
stop:
docker-compose down
# Build the user submission
user:
go build -o judgement ./app/judgement/cmd/main.go
# Run the user submission
user_run:
go run ./app/judgement/cmd/main.go
# Build the monolithic main function
main:
go build -o online_judge main.go
# Run the monolithic main function
main_run:
go run main.go
# Download the required dependencies
mod:
go mod tidy
# Delete all of the binary files generated by the makefile
clear:
rm -f judgement online_judge
# Display help information
help:
@echo "make - Download dependencies, build user submission and main function"
@echo "make start - Start the environment of online judge"
@echo "make stop - Stop the environment of online judge"
@echo "make user - Build the user submission"
@echo "make main - Build the monolithic main function"
@echo "make mod - Download the required dependencies"
@echo "make clear - Delete all of the binary files"
@echo "make help - Display this help message"
@echo "make user_run - Run the user submission"
@echo "make main_run - Run the monolithic main function"