2020-05-09 22:49:03 +02:00
|
|
|
.PHONY: chromad upload all
|
|
|
|
|
2021-08-04 20:11:59 +02:00
|
|
|
VERSION ?= $(shell git describe --tags --dirty --always)
|
|
|
|
|
2020-05-09 22:49:03 +02:00
|
|
|
all: README.md tokentype_string.go
|
|
|
|
|
|
|
|
README.md: lexers/*/*.go
|
|
|
|
./table.py
|
|
|
|
|
|
|
|
tokentype_string.go: types.go
|
|
|
|
go generate
|
|
|
|
|
|
|
|
chromad:
|
|
|
|
rm -f chromad
|
2023-01-28 22:55:14 +01:00
|
|
|
(export CGOENABLED=0 GOOS=linux GOARCH=amd64; cd ./cmd/chromad && go build -ldflags="-X 'main.version=$(VERSION)'" -o ../../chromad .)
|
2020-05-09 22:49:03 +02:00
|
|
|
|
|
|
|
upload: chromad
|
|
|
|
scp chromad root@swapoff.org: && \
|
|
|
|
ssh root@swapoff.org 'install -m755 ./chromad /srv/http/swapoff.org/bin && service chromad restart'
|