nar

simple archives
git clone git://git.kocotian.pl/nar.git
Log | Files | Refs | LICENSE

commit 50ffbe1de5b155172a4a286b5a4bf9a3dfd00c28
parent 2eea68590658c4e57146eb27c9a9e1c4b4fd4828
Author: kocotian <kocotian@kocotian.pl>
Date:   Thu, 28 Jan 2021 20:58:16 +0100

version under -V, todo list

Diffstat:
MMakefile | 4++++
ATODO | 3+++
Mconfig.mk | 2+-
Mnar.c | 5++++-
4 files changed, 12 insertions(+), 2 deletions(-)

diff --git a/Makefile b/Makefile @@ -25,4 +25,8 @@ nar: ${OBJ} clean: rm -f nar ${OBJ} *.orig *.rej +install: all + mkdir -p ${DESTDIR}${PREFIX}/bin + install -Dm755 nar ${DESTDIR}${PREFIX}/bin + .PHONY: all options clean diff --git a/TODO b/TODO @@ -0,0 +1,3 @@ += TODO = +* directories +* filetype fix diff --git a/config.mk b/config.mk @@ -5,7 +5,7 @@ PREFIX = /usr/local # flags CFLAGS = -std=c99 -Wall -pedantic -Os -CPPFLAGS = -D_XOPEN_SOURCE=700 +CPPFLAGS = -D_XOPEN_SOURCE=700 -DVERSION=\"${VERSION}\" # compiler CC = gcc diff --git a/nar.c b/nar.c @@ -131,7 +131,7 @@ extract(char *fn) void usage(void) { - die("usage: %s [-cx] [-v] [-f filename]", argv0); + die("usage: %s [-cx] [-vV] [-f filename]", argv0); } int @@ -152,6 +152,9 @@ main(int argc, char *argv[]) case 'v': verbose = 1; break; + case 'V': + die("nar-"VERSION); + break; case 'f': filename = ARGF(); break;