66 lines
1.3 KiB
Makefile
66 lines
1.3 KiB
Makefile
VERSION = $(shell git describe --tags)
|
|
BUILDTIME = $(shell date +%Y.%m.%d)
|
|
|
|
run: build
|
|
./go-clone --version
|
|
|
|
vet:
|
|
@GO111MODULE=off go vet
|
|
@echo this go library package builds okay
|
|
|
|
no-gui: build
|
|
./go-clone --no-gui
|
|
|
|
build:
|
|
make -C ../../lib/protobuf/gitpb/
|
|
GO111MODULE=off go build \
|
|
-ldflags "-X main.VERSION=${VERSION} -X main.BUILDTIME=${BUILDTIME} -X gui.GUIVERSION=${VERSION}"
|
|
|
|
install:
|
|
GO111MODULE=off go install \
|
|
-ldflags "-X main.VERSION=${VERSION} -X main.BUILDTIME=${BUILDTIME} -X gui.GUIVERSION=${VERSION}"
|
|
|
|
goimports:
|
|
goimports -w *.go
|
|
# // to globally reset paths:
|
|
# // gofmt -w -r "go.wit.com/gui -> go.wit.com/gui/gui" .
|
|
|
|
redomod:
|
|
rm -f go.*
|
|
GO111MODULE= go mod init
|
|
GO111MODULE= go mod tidy
|
|
go mod edit -go=1.20
|
|
|
|
reset:
|
|
# clear your terminal
|
|
reset
|
|
|
|
gui-gocui: build
|
|
reset
|
|
./go-clone --gui gocui >/tmp/witgui.log.stderr 2>&1
|
|
|
|
nocui: reset build
|
|
./go-clone --gui nocui
|
|
|
|
clean:
|
|
-rm go-clone
|
|
|
|
# this will test the golang.org/x -> googlesource override
|
|
git-clone:
|
|
./go-clone --recursive --go-src --no-work go.wit.com/lib/daemons/virtigod
|
|
|
|
debian:
|
|
go-deb --no-gui --repo go.wit.com/apps/go-clone
|
|
|
|
pull: build
|
|
./go-clone --dry-run --pull
|
|
|
|
pullreal: build
|
|
./go-clone --pull
|
|
|
|
fetch: build
|
|
./go-clone --dry-run --fetch
|
|
|
|
modernc: build
|
|
./go-clone --no-work --recursive modernc.org/sqlite
|