Makefile 726 B

123456789101112131415161718192021222324252627
  1. # Copyright 2024 The ngrab Authors. All rights reserved.
  2. # Use of this source code is governed by a BSD-style
  3. # license that can be found in the LICENSE file.
  4. .PHONY: all clean edit editor test
  5. all: editor
  6. golint 2>&1
  7. staticcheck 2>&1
  8. clean:
  9. rm -f log-* cpu.test mem.test *.out go.work*
  10. go clean
  11. edit:
  12. @touch log
  13. @if [ -f "Session.vim" ]; then gvim -S & else gvim -p Makefile *.go & fi
  14. editor:
  15. gofmt -l -s -w . 2>&1 | tee log-editor
  16. # go test -c -o /dev/null 2>&1 | tee -a log-editor
  17. go build -v -o /dev/null ./... 2>&1 | tee -a log-editor
  18. go test 2>&1 | tee -a log-editor
  19. test:
  20. go test -v -timeout 24h -count=1 2>&1 | tee log-test
  21. grep -a 'TRC\|TODO\|ERRORF\|FAIL' log-test || true 2>&1 | tee -a log-test