commit 2a3aa8ec0c8405ec71937108765bef0faf6f4d49
parent f709107300338c07130648c3eb03492aef3c2880
Author: Christoph Lohmann <20h@r-36.net>
Date:   Sat,  2 Jul 2011 12:35:56 +0200
README.md is gone. Added manpage.
Diffstat:
| Makefile | | | 2 | +- | 
| README.md | | | 53 | ----------------------------------------------------- | 
| thinglaunch.1 | | | 129 | +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ | 
3 files changed, 130 insertions(+), 54 deletions(-)
diff --git a/Makefile b/Makefile
@@ -39,7 +39,7 @@ clean:
 dist: clean
 	@echo creating dist tarball
 	@mkdir -p ${NAME}-${VERSION}
-	@cp -R LICENSE LICENSE.orig Makefile README.md config.mk \
+	@cp -R LICENSE LICENSE.orig ${NAME}.1 Makefile config.mk \
 		${SRC} *.h ${NAME}-${VERSION}
 	@tar -cf ${NAME}-${VERSION}.tar ${NAME}-${VERSION}
 	@gzip ${NAME}-${VERSION}.tar
diff --git a/README.md b/README.md
@@ -1,53 +0,0 @@
-# Thinglaunch - a simple entry box for X11 
-
-The first intention, as done by the original creator Matt Johnston
-<matt@ucc.asn.au>, was to launch simple commandlines.
-
-In 2011 the single file project was extended by features like Unicode
-support, a prompt and an ssh-askpass compatibility layer.
-
-## Installation
-
-	% tar -xzvf thinglaunch-*.tar.gz
-	% cd thinglaunch
-	% make
-	% sudo PREFIX=/usr make install
-
-This will create the executable »thinglaunch« and »thingaskpass« in
-»/usr/bin«. Thinglaunch will ask for a command and execute it and
-thingaskpass can be used as a SSH_ASKPASS parameter value, which will
-be used by ssh-agent to gather the password for private keys.
-
-## Usage
-
-	# Get some input string and print it to stdout. There will
-	# be the prompt prepended "to stdout> ".
-	% thinglaunch -o -p "to stdout> "
-
-	# Ask for a command, which will be executed. During entering
-	# the command, the entered string will be replaced by asterisks. 
-	% thinglaunch -s -p "secret cmd> "
-
-	# This symlink predefines -s, -o and -p "secret> ".
-	% ln -s thinglaunch thingaskpass
-	% ./thingaskpass
-
-	# This symlink predefined -s, -o and takes the prompt as first
-	# argument.
-	% ln -s thinglaunch thingsudoaskpass
-	% ./thingsudoaskpass
-
-## SSH_ASKPASS
-
-If you set SSH_ASKPASS to the PATH to thingaskpass (usually /usr/bin/
-thingaskpass), then ssh-agent will use this command for asking for pass-
-words.
-
-## SUDO_ASKPASS
-
-This is the same as SSH_ASKPASS, but here you need to set SUDO_ASKPASS
-to the PATH to thingsudoaskpass (usually /usr/bin/thingsudoaskpass).
-
-
-Have fun!
-
diff --git a/thinglaunch.1 b/thinglaunch.1
@@ -0,0 +1,129 @@
+.Dd July 02, 2011
+.Dt THINGLAUNCH 1
+.Os
+.
+.Sh NAME
+.Nm thinglaunch 
+.Nd a simple prompt for X11 
+.
+.Sh SYNOPSIS
+.Nm
+.Bk -words
+.Op Fl o
+.Op Fl s
+.Op Fl p Ar prompt
+.Ek
+.
+.Sh DESCRIPTION
+.Bd -filled
+.Nm
+is a simple password prompt for X11, which will input a string and then do
+various things with it. It is used as password prompt, execution prompt and
+can be easily extended.
+.Ed
+. 
+.Sh IMPLEMENTATION
+.Bd -filled
+Installation is as straighforward as grabbing the tar.gz file, extracting
+it and running
+.Qq "make; make install;"
+inside the
+.Qq "thinglaunch-*"
+directory.
+The prefix for the installation can easily set using
+.Qq "PREFIX=/usr make install".
+.Ed
+.
+.Sh OPTIONS
+.Nm
+options and default settings.
+.Pp
+.Bl -tag -width ".Fl test Ao Ar string Ac"
+.
+.It Fl o
+Print prompted string to stdout.
+.
+.It Fl s
+The input string will be shown as
+.Qq "*"
+instead of cleartext.
+.
+.Fl Fl p Ar prompt
+Specify the prompt, which should be shown before the text entry.
+.
+.El
+.
+.Sh CUSTOMIZATION 
+.Bd -filled
+.Nm
+is customized by creating a custom config.h and (re)compiling the
+source code.
+.Ed
+.
+.Sh SYMLINKS
+.Bd -filled
+The behaviour of
+.Nm
+can be controlled using various symlinks to the main executable or by renaming
+the executable.
+.Ed
+.Bd -filled
+When
+.Nm is run as
+.Qq "thingaskpass",
+then -s and -o are implied and a prompt of
+.Qq "secret> "
+is set. This is useful when used with
+.Qq "ssh-agent",
+which respects the
+.Ev SSH_ASKPASS
+environment variable.
+.Ed
+.Bd -filled
+Calling
+.Nm
+as
+.Qq "thingsudoaskpass"
+implies -s, -o and a prompt according to the first commandline parameter or
+.Qq "secret sudo> ".
+This mode is useful in conjunction with
+.Qq "sudo",
+which respects the
+.Ev SUDO_ASKPASS
+environment variable.
+.Ed
+.
+.Sh EXAMPLES
+.Bd -filled
+Get some input string and print it to stdout. The prompt will be changed to
+.Qq "to stdout> ".
+.Ed
+.Bd -literal
+	% thinglaunch -s -p "to stdout> "
+
+.Ed
+.Bd -filled
+Ask for a command, which will be executed. The entered string will be secured
+using
+.Qq "*".
+.Ed
+.Bd -literal
+	% thinglaunch -s -p "secret cmd> "
+
+.Ed
+.
+.Sh FILES
+LICENSE, config.def.h, config.h
+.
+.Sh AUTHORS
+See LICENSE file for authors in the distribution.
+.
+.Sh LICENSE
+.Nm
+is released under the MIT/X Consortium License.
+.
+.Sh BUGS
+.Ss "Reporting Bugs"
+Report bugs to: 
+.An "Christoph Lohmann" Aq 20h@R-36.net
+