summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoey Hess2014-11-22 12:09:53 -0400
committerJoey Hess2014-11-22 12:13:38 -0400
commit57ec60d6f307dbf3e237b924e635b90ba889af18 (patch)
tree3655b8befb6e905f903903887974a1a976cfd0bf
parente0c2d6a73af01f138a50b80a6885718ed0b9dad1 (diff)
mdwn man page and more complete docs
-rw-r--r--Makefile7
-rw-r--r--debian/changelog2
-rw-r--r--doc/documentation.mdwn1
-rwxr-xr-xdoc/mdwn2man44
-rw-r--r--propellor.115
5 files changed, 52 insertions, 17 deletions
diff --git a/Makefile b/Makefile
index 61d32424..459fae36 100644
--- a/Makefile
+++ b/Makefile
@@ -19,7 +19,7 @@ dist/setup-config: propellor.cabal
@if [ "$(CABAL)" = ./Setup ]; then ghc --make Setup; fi
@$(CABAL) configure
-install:
+install: propellor.1
install -d $(DESTDIR)/usr/bin $(DESTDIR)/usr/src/propellor
install -s dist/build/propellor/propellor $(DESTDIR)/usr/bin/propellor
mkdir -p dist/gittmp
@@ -34,8 +34,11 @@ install:
&& git show-ref master --hash > $(DESTDIR)/usr/src/propellor/head
rm -rf dist/gittmp
+propellor.1: doc/usage.mdwn doc/mdwn2man
+ doc/mdwn2man propellor 1 < doc/usage.mdwn > propellor.1
+
clean:
- rm -rf dist Setup tags propellor privdata/local
+ rm -rf dist Setup tags propellor propellor.1 privdata/local
find -name \*.o -exec rm {} \;
find -name \*.hi -exec rm {} \;
diff --git a/debian/changelog b/debian/changelog
index 784dcdb7..a44d72af 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -3,6 +3,8 @@ propellor (1.0.1) UNRELEASED; urgency=medium
* propellor --spin can now deploy propellor to hosts that do not have
git, ghc, or apt-get. This is accomplished by uploading a fairly
portable precompiled tarball of propellor.
+ * --spin host --via host causes propellor to bounce through an intermediate
+ host, which handles any necessary provisioning of the host being spun.
-- Joey Hess <joeyh@debian.org> Sat, 22 Nov 2014 00:12:35 -0400
diff --git a/doc/documentation.mdwn b/doc/documentation.mdwn
index 79e242f4..9028dfaa 100644
--- a/doc/documentation.mdwn
+++ b/doc/documentation.mdwn
@@ -3,6 +3,7 @@ Propellor's modules is the most important docuemntation of propellor.
Other documentation:
+* [[man page|usage]]
* [[Haskell Newbie]]
* [[Centralized Git Repository]]
* [[Contributing]]
diff --git a/doc/mdwn2man b/doc/mdwn2man
new file mode 100755
index 00000000..aadb13cd
--- /dev/null
+++ b/doc/mdwn2man
@@ -0,0 +1,44 @@
+#!/usr/bin/env perl
+# Warning: hack
+
+my $prog=shift;
+my $section=shift;
+
+print ".TH $prog $section\n";
+
+while (<>) {
+ s{(\\?)\[\[([^\s\|\]]+)(\|[^\s\]]+)?\]\]}{$1 ? "[[$2]]" : $2}eg;
+ s/\`([^\`]*)\`/\\fB$1\\fP/g;
+ s/\`//g;
+ s/^\s*\./\\&./g;
+ if (/^#\s/) {
+ s/^#\s/.SH /;
+ <>; # blank;
+ }
+ s/^[ \n]+//;
+ s/^\t/ /;
+ s/-/\\-/g;
+ s/^Warning:.*//g;
+ s/^$/.PP\n/;
+ s/^\*\s+(.*)/.IP "$1"/;
+ next if $_ eq ".PP\n" && $skippara;
+ if (/^.IP /) {
+ $inlist=1;
+ $spippara=0;
+ }
+ elsif (/^.SH/) {
+ $skippara=0;
+ $inlist=0;
+ }
+ elsif (/^\./) {
+ $skippara=1;
+ }
+ else {
+ $skippara=0;
+ }
+ if ($inlist && $_ eq ".PP\n") {
+ $_=".IP\n";
+ }
+
+ print $_;
+}
diff --git a/propellor.1 b/propellor.1
deleted file mode 100644
index 27547f10..00000000
--- a/propellor.1
+++ /dev/null
@@ -1,15 +0,0 @@
-.\" -*- nroff -*-
-.TH propellor 1 "Commands"
-.SH NAME
-propellor \- property-based host configuration management in haskell
-.SH SYNOPSIS
-.B propellor [options] host
-.SH DESCRIPTION
-.I propellor
-is a property-based host configuration management program written
-and configured in haskell.
-.PP
-The first time you run propellor, it will set up a ~/.propellor/
-repository. Edit ~/.propellor/config.hs to configure it.
-.SH AUTHOR
-Joey Hess <id@joeyh.name>