wmii

git clone git://oldgit.suckless.org/wmii/
Log | Files | Refs | README | LICENSE

commit 286003998aef73500622cbca7b9eab34a9d589b5
parent 1d62fa5b06ca854421508bff1cc461c4e5b5bdd7
Author: Kris Maglione <jg@suckless.org>
Date:   Tue,  3 Jul 2007 10:16:14 -0400

Run latex2man. Other cleanup.

Diffstat:
Makefile | 2+-
cmd/wmiir.c | 9+++++++--
debian/rules | 4++--
man/wmii.1 | 14+++++++-------
mk/hdr.mk | 15++++-----------
mk/many.mk | 1+
6 files changed, 22 insertions(+), 23 deletions(-)

diff --git a/Makefile b/Makefile @@ -17,7 +17,7 @@ config: ROOT="${ROOT}" ${ROOT}/util/genconfig deb-dep: - apt-get install build-essential debhelper libxext-dev x11proto-xext-dev libx11-dev + apt-get -qq install build-essential debhelper libxext-dev x11proto-xext-dev libx11-dev deb: dpkg-buildpackage -rfakeroot diff --git a/cmd/wmiir.c b/cmd/wmiir.c @@ -117,6 +117,7 @@ xwrite(int argc, char *argv[]) { fatal("Can't open file '%s': %r\n", file); write_data(fid, file); + ixp_close(fid); return 0; } @@ -142,7 +143,7 @@ xawrite(int argc, char *argv[]) { while(argc) { arg = ARGF(); len = strlen(arg); - if(nbuf + len > mbuf) { + if(nbuf + len + 1 > mbuf) { mbuf <<= 1; buf = erealloc(buf, mbuf); } @@ -154,6 +155,8 @@ xawrite(int argc, char *argv[]) { if(ixp_write(fid, buf, nbuf) == -1) fatal("cannot write file '%s': %r\n", file); + ixp_close(fid); + free(buf); return 0; } @@ -174,7 +177,7 @@ xcreate(int argc, char *argv[]) { if((fid->qid.type&P9_DMDIR) == 0) write_data(fid, file); - + ixp_close(fid); return 0; } @@ -212,6 +215,7 @@ xread(int argc, char *argv[]) { buf = emalloc(fid->iounit); while((count = ixp_read(fid, buf, fid->iounit)) > 0) write(1, buf, count); + ixp_close(fid); if(count == -1) fatal("cannot read file/directory '%s': %r\n", file); @@ -272,6 +276,7 @@ xls(int argc, char *argv[]) { ixp_pstat(&m, &stat[nstat++]); } } + ixp_close(fid); qsort(stat, nstat, sizeof(*stat), comp_stat); for(i = 0; i < nstat; i++) { diff --git a/debian/rules b/debian/rules @@ -61,7 +61,7 @@ patch: awk -f "${PATCHES}/un$$base.awk" $$files >>debian/unpatch.ed; \ for f in $$files; do \ cat <"${PATCHES}/$$base.ed"; \ - ed $$f <"${PATCHES}/$$base.ed"; \ + ed -s $$f <"${PATCHES}/$$base.ed"; \ done; \ done; \ fi @@ -69,7 +69,7 @@ patch: unpatch: set -e; \ if [ -e ${UNPATCH} ]; then \ - ed <${UNPATCH}; \ + ed -s <${UNPATCH}; \ rm ${UNPATCH}; \ fi diff --git a/man/wmii.1 b/man/wmii.1 @@ -1,5 +1,5 @@ '\" t -.\" Manual page created with latex2man on Mon Jul 2 12:45:18 EDT 2007 +.\" Manual page created with latex2man on Tue Jul 3 10:15:50 EDT 2007 .\" NOTE: This file is generated, DO NOT EDIT. .de Vb .ft CW @@ -10,7 +10,7 @@ .fi .. -.TH "WMII" "1" "02 July 2007" "" "" +.TH "WMII" "1" "03 July 2007" "" "" .SH NAME wmii\-VERSION .PP @@ -107,7 +107,7 @@ character. .TP View A set of clients containing a specific tag, quite -similiar to a workspace in other window managers. It +similar to a workspace in other window managers. It consists of the floating and managed layers. .TP Column @@ -560,12 +560,12 @@ Returns a clients class and label as: \fIname\fP:\fIclass\fP:\fIlabel\fP .TP tags -Set or read a client\&'s tags. Tags are seperated by +Set or read a client\&'s tags. Tags are separated by \fI+\fP or \fI\-\fP\&. -Tags begining with \fI+\fP +Tags beginning with \fI+\fP are -added, while those begining with \fI\-\fP +added, while those beginning with \fI\-\fP are removed. If the tag string written begins with \fI+\fP or @@ -645,7 +645,7 @@ occupying all extra available space. The items are sorted lexicographically. .PP The files may be read to obtain the colors and text of the bars. -The colors are at the begining of the string, represented as a +The colors are at the beginning of the string, represented as a tuple of 3 hex color codes for the foreground, background, and border, respectively. When writing the bar files, the colors may be omitted if the text would not otherwise appear to contain diff --git a/mk/hdr.mk b/mk/hdr.mk @@ -6,6 +6,9 @@ all: echo MKDEP $< ${MKDEP} ${CFLAGS} $< >>.depend +.sh.depend .rc.depend .1.depend .awk.depend: + : + .c.o: ${COMPILE} $@ $< @@ -16,17 +19,7 @@ all: ${COMPILE} $@ $< ${LINK} $@ $< -.awk.O: - echo FILTER ${BASE}$< - ${FILTER} $< >$@ - chmod 0755 $@ - -.rc.O: - echo FILTER ${BASE}$< - ${FILTER} $< >$@ - chmod 0755 $@ - -.sh.O: +.rc.O .sh.O .awk.O: echo FILTER ${BASE}$< ${FILTER} $< >$@ chmod 0755 $@ diff --git a/mk/many.mk b/mk/many.mk @@ -4,6 +4,7 @@ all: ${OFILES} ${PROGS} install: ${TARG:=.install} uninstall: ${TARG:=.uninstall} +depend: ${OFILES:.o=.depend} ${TARG:=.depend} clean: manyclean printinstall: