diff --git a/bots/build.sh b/bots/build.sh new file mode 100755 index 00000000..bf4b428d --- /dev/null +++ b/bots/build.sh @@ -0,0 +1,4 @@ +#!/bin/sh +MYDIR="$(dirname "$(realpath "$0")")" +cd "$MYDIR" +for dir in ./*; do ([ -d "$dir" ] && cd "$dir" && echo "Building bots/$dir" && go build); done \ No newline at end of file diff --git a/jobs/build.sh b/jobs/build.sh index 2839f06f..48a4e138 100755 --- a/jobs/build.sh +++ b/jobs/build.sh @@ -1,4 +1,5 @@ #!/bin/sh MYDIR="$(dirname "$(realpath "$0")")" cd "$MYDIR" +go build for dir in ./*; do ([ -d "$dir" ] && cd "$dir" && echo "Building jobs/$dir" && go build); done \ No newline at end of file diff --git a/makefile b/makefile index d8ca17b9..9c2a429c 100644 --- a/makefile +++ b/makefile @@ -6,6 +6,7 @@ GOINSTALL=$(GOCMD) install GOTEST=$(GOCMD) test BUILDJOBS=@./jobs/build.sh BUILDPATCHES=@./patches/build.sh +BUILDBOTS=@./bots/build.sh TSCMD=@tsc IPTABLES=@sudo iptables @@ -13,6 +14,8 @@ server: $(GOBUILD) jobs: $(BUILDJOBS) +bots: + $(BUILDBOTS) patches: $(BUILDPATCHES) js: @@ -42,6 +45,6 @@ clean: ports: $(IPTABLES) -t nat -A OUTPUT -o lo -p tcp --dport 80 -j REDIRECT --to-port 4000 $(IPTABLES) -t nat -A OUTPUT -o lo -p tcp --dport 443 -j REDIRECT --to-port 4001 -all: assets server jobs patches +all: assets server bots jobs patches -.PHONY: jobs patches ports +.PHONY: bots jobs patches ports