-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
46 lines (34 loc) · 1.3 KB
/
Makefile
File metadata and controls
46 lines (34 loc) · 1.3 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
SHELL := /usr/bin/env bash
.PHONY: help generate fmt test plugins plugins-docker dev-plugins run run-remote run-server dev
help:
@echo "Targets:"
@echo " make generate - regenerate interop bindings"
@echo " make fmt - format Go source files"
@echo " make test - run go test ./..."
@echo " make plugins - build C# example plugins into ./plugins/csharp"
@echo " make plugins-docker - build C# example plugins using Docker only"
@echo " make dev-plugins - build plugins and print in-game reload reminder"
@echo " make run - run ./start.sh using local host source (USE_LOCAL_HOST_WORKTREE=1)"
@echo " make run-remote - run ./start.sh using cached/fetched host source"
@echo " make run-server - run server directly (go run ./cmd)"
@echo " make dev - generate + fmt + test + plugins"
generate:
cd internal/generator && go run ./cmd
fmt:
gofmt -w $$(find . -type f -name '*.go')
test:
go test ./...
plugins:
./build_plugins.sh
plugins-docker:
./build_plugins_docker.sh
dev-plugins: plugins
@echo "plugins rebuilt. run /pl reload all in-game."
run:
USE_LOCAL_HOST_WORKTREE=1 ./start.sh
run-remote:
./start.sh
run-server:
go run ./cmd
dev: generate fmt test plugins
@echo "dev cycle complete. if server is running, run /pl reload all in-game."