summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRémy Oudompheng <remy@archlinux.org>2011-06-19 21:01:55 +0200
committerRémy Oudompheng <remy@archlinux.org>2011-06-19 21:01:55 +0200
commit43926c44661a9f8499b3fb9775e1cfdd4aef2bdf (patch)
treec8a01d6692bd8132971db7e4cbc12689856cdb71
parentc45d8ae987272cc64ec84d00de44f16c69e03034 (diff)
downloadnetctl-43926c44661a9f8499b3fb9775e1cfdd4aef2bdf.tar.gz
netctl-43926c44661a9f8499b3fb9775e1cfdd4aef2bdf.tar.xz
Allow using markdown instead of pandoc, packaging fixes
Signed-off-by: Rémy Oudompheng <remy@archlinux.org>
-rw-r--r--Makefile9
-rw-r--r--README4
-rwxr-xr-xdocs/make.sh14
-rwxr-xr-xscripts/netcfg2
4 files changed, 21 insertions, 8 deletions
diff --git a/Makefile b/Makefile
index 07391a1..a0074e3 100644
--- a/Makefile
+++ b/Makefile
@@ -1,5 +1,5 @@
DESTDIR=
-VERSION=2.6
+VERSION=2.6rc1
VPATH = doc
.PHONY: install docs
@@ -45,13 +45,12 @@ install-docs: docs
install -m644 contrib/* $(DESTDIR)/usr/share/doc/netcfg/contrib/
docs:
- cd docs; \
- ./make.sh
+ cd docs && ./make.sh
tarball: docs
- sed -i "s/NETCFG_VER=.*/NETCFG_VER=$(VERSION)/g" src/netcfg
+ sed -i "s/NETCFG_VER=.*/NETCFG_VER=$(VERSION)/g" scripts/netcfg
mkdir -p netcfg-$(VERSION)
- cp -r src src-wireless ifplugd wpa_actiond examples contrib man Makefile LICENSE README netcfg-$(VERSION)
+ cp -r src scripts src-wireless ifplugd wpa_actiond examples contrib man Makefile LICENSE README netcfg-$(VERSION)
tar -zcvf netcfg-$(VERSION).tar.gz netcfg-$(VERSION)
rm -rf netcfg-$(VERSION)
diff --git a/README b/README
index 427c670..7121de0 100644
--- a/README
+++ b/README
@@ -17,3 +17,7 @@ For wireless support:
Deprecated dependencies:
- net-tools (only used in IFOPTS option)
- wireless_tools (only used for IWCONFIG option, still necessary for wireless connection)
+
+For documentation generation:
+- python-markdown, or pandoc
+
diff --git a/docs/make.sh b/docs/make.sh
index 544d1f3..76a30af 100755
--- a/docs/make.sh
+++ b/docs/make.sh
@@ -1,7 +1,17 @@
#! /bin/bash
PAGES=(ethernet features wireless)
+make_page() {
+ echo '<html><body>'
+ grep -v '^%' $1 | markdown -x def_list -x headerid /dev/stdin
+ echo '</body></html>'
+}
+
for page in ${PAGES[@]}; do
- rm ${page}.html
- pandoc -s --toc -w html --email-obfuscation=javascript -c header.css -o ${page}.html $page
+ rm -f ${page}.html
+ if [ -f /usr/bin/pandoc ]; then
+ pandoc -s --toc -w html --email-obfuscation=javascript -c header.css -o ${page}.html $page
+ else
+ make_page $page > ${page}.html
+ fi
done
diff --git a/scripts/netcfg b/scripts/netcfg
index e00794d..7b8fa8a 100755
--- a/scripts/netcfg
+++ b/scripts/netcfg
@@ -2,7 +2,7 @@
. /usr/lib/network/network
-NETCFG_VER=2.6
+NETCFG_VER=2.6rc1
version()
{