File: Makefile

package info (click to toggle)
mgitstatus 2.2%2Bdfsg-2
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 184 kB
  • sloc: sh: 258; makefile: 38
file content (26 lines) | stat: -rw-r--r-- 663 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
SHELL := /bin/sh

PREFIX ?= /usr/local

.PHONY: all
all: man

mgitstatus.1: mgitstatus.1.md
		pandoc ./$< -s -t man > $@

.PHONY: man
man: mgitstatus.1

.PHONY: test
test:
		# SC1117 Backslash is literal in...
		# SC2059 Don't use variables in the printf format string. But we need to or colors won't work
		# SC2012 Use find instead of ls, but we need to extract the user id of the .git dir
		shellcheck -e SC1117,SC2059,SC2012 mgitstatus

.PHONY: install
install:
		install -d $(DESTDIR)$(PREFIX)/bin
		install -d $(DESTDIR)$(PREFIX)/share/man/man1
		install -m 755 mgitstatus $(DESTDIR)$(PREFIX)/bin/
		install mgitstatus.1 $(DESTDIR)$(PREFIX)/share/man/man1/