Skip to content

Commit

Permalink
Add package target
Browse files Browse the repository at this point in the history
  • Loading branch information
zyedidia committed Jan 17, 2021
1 parent 047cb20 commit c5efba5
Show file tree
Hide file tree
Showing 5 changed files with 20 additions and 202 deletions.
5 changes: 4 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
/perforator
/cmd/perforator/perforator
todo.txt
test/sum
/test/sum

perforator.1
/perforator-*
18 changes: 16 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,23 @@ GOVARS = -X main.Version=$(VERSION)

build:
go build -trimpath -ldflags "-s -w $(GOVARS)" ./cmd/perforator

install:
go install -trimpath -ldflags "-s -w $(GOVARS)" ./cmd/perforator

perforator.1: man/perforator.md
pandoc man/perforator.md -s -t man -o perforator.1

package: build perforator.1
mkdir perforator-$(VERSION)
cp README.md perforator-$(VERSION)
cp LICENSE perforator-$(VERSION)
cp perforator.1 perforator-$(VERSION)
cp perforator perforator-$(VERSION)
tar -czf perforator-$(VERSION).tar.gz perforator-$(VERSION)

clean:
rm -f perforator
rm -f perforator perforator.1 perforator-*.tar.gz
rm -rf perforator-*/

.PHONY: build clean install
.PHONY: build clean install package
1 change: 0 additions & 1 deletion go.sum
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
acln.ro/perf v0.0.0-20200512125540-4d8e4e566115 h1:LXxt66Jv2YsU40F2p/VykMEUMulv2oRHrZHrEe+0V/0=
acln.ro/perf v0.0.0-20200512125540-4d8e4e566115/go.mod h1:YNATxll6AOOkbTRJWdm3bSvTzXor3Hs5U9IzIYpfBCI=
github.com/blang/semver v1.1.0 h1:ol1rO7QQB5uy7umSNV7VAmLugfLRD+17sYJujRNYPhg=
github.com/blang/semver v3.5.1+incompatible h1:cQNTCjp13qL8KC3Nbxr/y2Bqb63oX6wdnnjpJbkM4JQ=
github.com/blang/semver v3.5.1+incompatible/go.mod h1:kRBLl5iJ+tD4TcOOxsy/0fnwebNt5EWlYSAyrTnjyyk=
github.com/jessevdk/go-flags v1.4.0 h1:4IU2WS7AumrZ/40jfhf4QVDMsQwqA7VEHozFRrGARJA=
Expand Down
2 changes: 0 additions & 2 deletions man/Makefile

This file was deleted.

196 changes: 0 additions & 196 deletions man/perforator.1

This file was deleted.

0 comments on commit c5efba5

Please sign in to comment.