aboutsummaryrefslogtreecommitdiff
path: root/share/templater/pelican
diff options
context:
space:
mode:
authorSilvio Rhatto <rhatto@riseup.net>2017-10-31 17:23:15 -0200
committerSilvio Rhatto <rhatto@riseup.net>2017-10-31 17:23:15 -0200
commit82e6bce4ea8fc61e99f6eb32dc12c470b93dccd4 (patch)
tree4b81210f80e8a3e85a1d65b01beb67f92a727066 /share/templater/pelican
parent8e83eb20f8841022cf9a221f2e8447cdba1f7270 (diff)
downloadtemplater-82e6bce4ea8fc61e99f6eb32dc12c470b93dccd4.tar.gz
templater-82e6bce4ea8fc61e99f6eb32dc12c470b93dccd4.tar.bz2
New module format
Diffstat (limited to 'share/templater/pelican')
-rw-r--r--share/templater/pelican/description1
-rw-r--r--share/templater/pelican/files/.gitignore (renamed from share/templater/pelican/.gitignore)0
-rw-r--r--share/templater/pelican/files/Makefile (renamed from share/templater/pelican/Makefile)0
-rw-r--r--share/templater/pelican/files/pelicanconf.py (renamed from share/templater/pelican/pelicanconf.py)0
-rwxr-xr-xshare/templater/pelican/setup39
5 files changed, 40 insertions, 0 deletions
diff --git a/share/templater/pelican/description b/share/templater/pelican/description
new file mode 100644
index 0000000..b7ebaae
--- /dev/null
+++ b/share/templater/pelican/description
@@ -0,0 +1 @@
+Pelican static site compiler
diff --git a/share/templater/pelican/.gitignore b/share/templater/pelican/files/.gitignore
index 06a38a6..06a38a6 100644
--- a/share/templater/pelican/.gitignore
+++ b/share/templater/pelican/files/.gitignore
diff --git a/share/templater/pelican/Makefile b/share/templater/pelican/files/Makefile
index 45fb995..45fb995 100644
--- a/share/templater/pelican/Makefile
+++ b/share/templater/pelican/files/Makefile
diff --git a/share/templater/pelican/pelicanconf.py b/share/templater/pelican/files/pelicanconf.py
index c5f6dd3..c5f6dd3 100644
--- a/share/templater/pelican/pelicanconf.py
+++ b/share/templater/pelican/files/pelicanconf.py
diff --git a/share/templater/pelican/setup b/share/templater/pelican/setup
new file mode 100755
index 0000000..93375ad
--- /dev/null
+++ b/share/templater/pelican/setup
@@ -0,0 +1,39 @@
+#!/bin/bash
+#
+# Pelican templater module.
+#
+
+# Parameters
+SHARE="$1"
+
+# Include basic functions
+source $SHARE/templater/functions || exit 1
+
+# Pelican implementation
+function templater_pelican {
+ if [ ! -e "pelicanconf.py" ]; then
+ __templater_echo "Setting up pelican..."
+
+ #__templater_checkout_develop
+ __templater_copy_or_append pelican .gitignore
+
+ cp $SHARE/sphinx/files/pelicanconf.py .
+
+ if [ ! -e "Makefile" ]; then
+ cp $SHARE/pelican/files/Makefile .
+ #elif ! grep -q pelican Makefile; then
+ # grep -v '^#' $SHARE/pelican/files/Makefile >> Makefile
+ else
+ cp $SHARE/ikiwiki/files/Makefile Makefile.pelican
+ fi
+
+ if [ ! -d "content" ]; then
+ cp -r $SHARE/pelican/files/content .
+ fi
+ else
+ __templater_echo "Pelican already set"
+ fi
+}
+
+# Dispatch
+templater_pelican