2020-09-22 16:15:18 +02:00
|
|
|
.PHONY: all install build release capdefs test smoke gofmt irctest
|
2017-06-24 21:41:11 +02:00
|
|
|
|
2020-05-21 17:25:30 +02:00
|
|
|
GIT_COMMIT := $(shell git rev-parse HEAD 2> /dev/null)
|
2020-05-20 16:31:05 +02:00
|
|
|
|
2018-06-26 00:08:15 +02:00
|
|
|
capdef_file = ./irc/caps/defs.go
|
|
|
|
|
2019-02-21 09:29:39 +01:00
|
|
|
all: install
|
2017-06-24 21:41:11 +02:00
|
|
|
|
2020-02-12 19:19:23 +01:00
|
|
|
install:
|
2020-05-20 16:31:05 +02:00
|
|
|
go install -v -ldflags "-X main.commit=$(GIT_COMMIT)"
|
2020-02-10 02:51:23 +01:00
|
|
|
|
2020-02-12 19:19:23 +01:00
|
|
|
build:
|
2020-05-20 16:31:05 +02:00
|
|
|
go build -v -ldflags "-X main.commit=$(GIT_COMMIT)"
|
2017-07-26 00:04:23 +02:00
|
|
|
|
2020-02-12 19:19:23 +01:00
|
|
|
release:
|
2018-04-11 02:12:28 +02:00
|
|
|
goreleaser --skip-publish --rm-dist
|
|
|
|
|
2018-06-26 00:08:15 +02:00
|
|
|
capdefs:
|
|
|
|
python3 ./gencapdefs.py > ${capdef_file}
|
|
|
|
|
2017-07-26 00:04:23 +02:00
|
|
|
test:
|
2018-06-26 00:08:15 +02:00
|
|
|
python3 ./gencapdefs.py | diff - ${capdef_file}
|
2018-04-23 00:47:10 +02:00
|
|
|
cd irc && go test . && go vet .
|
2018-06-26 00:08:15 +02:00
|
|
|
cd irc/caps && go test . && go vet .
|
2019-05-12 10:01:47 +02:00
|
|
|
cd irc/cloaks && go test . && go vet .
|
2019-01-01 22:45:37 +01:00
|
|
|
cd irc/connection_limits && go test . && go vet .
|
2020-04-05 09:48:59 +02:00
|
|
|
cd irc/email && go test . && go vet .
|
2020-12-08 03:21:10 +01:00
|
|
|
cd irc/flatip && go test . && go vet .
|
2018-11-26 11:23:27 +01:00
|
|
|
cd irc/history && go test . && go vet .
|
2018-04-23 00:47:10 +02:00
|
|
|
cd irc/isupport && go test . && go vet .
|
2020-10-02 22:48:37 +02:00
|
|
|
cd irc/migrations && go test . && go vet .
|
2018-04-23 00:47:10 +02:00
|
|
|
cd irc/modes && go test . && go vet .
|
2020-02-19 01:38:42 +01:00
|
|
|
cd irc/mysql && go test . && go vet .
|
2018-08-06 04:51:39 +02:00
|
|
|
cd irc/passwd && go test . && go vet .
|
2018-04-23 00:47:10 +02:00
|
|
|
cd irc/utils && go test . && go vet .
|
2018-05-04 10:27:43 +02:00
|
|
|
./.check-gofmt.sh
|
2020-03-24 14:56:12 +01:00
|
|
|
|
|
|
|
smoke:
|
2020-06-15 00:54:36 +02:00
|
|
|
oragono mkcerts --conf ./default.yaml || true
|
|
|
|
oragono run --conf ./default.yaml --smoke
|
2020-06-17 08:14:23 +02:00
|
|
|
|
|
|
|
gofmt:
|
|
|
|
./.check-gofmt.sh --fix
|
2020-09-22 16:15:18 +02:00
|
|
|
|
|
|
|
irctest:
|
|
|
|
git submodule update --init
|
|
|
|
cd irctest && make integration
|