summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaul Buetow (centauri) <puppet@mx.buetow.org>2015-05-23 21:56:06 +0100
committerPaul Buetow (centauri) <puppet@mx.buetow.org>2015-05-23 21:56:06 +0100
commitd61778d5581229411b6ceddd6b5da584c3f41c4b (patch)
tree705cdae1209f468da6b864d6105572d576e90a0d
parent3c3eb7afd103011fb0bedabb85b2c49b75f8d3fa (diff)
parenta14add04680c5ad04774df753b93bfe3fe05d8f3 (diff)
Merge remote-tracking branch 'remotes/github/develop' into develop
-rw-r--r--docs/photoalbum.131
-rwxr-xr-xsrc/photoalbum.sh24
2 files changed, 32 insertions, 23 deletions
diff --git a/docs/photoalbum.1 b/docs/photoalbum.1
index 1e8e618..2ffd275 100644
--- a/docs/photoalbum.1
+++ b/docs/photoalbum.1
@@ -1,4 +1,4 @@
-.\" Automatically generated by Pod::Man 2.25 (Pod::Simple 3.16)
+.\" Automatically generated by Pod::Man 2.27 (Pod::Simple 3.28)
.\"
.\" Standard preamble:
.\" ========================================================================
@@ -38,6 +38,8 @@
. ds PI \(*p
. ds L" ``
. ds R" ''
+. ds C`
+. ds C'
'br\}
.\"
.\" Escape single quotes in literal strings from groff's Unicode transform.
@@ -48,17 +50,24 @@
.\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index
.\" entries marked with X<> in POD. Of course, you'll have to process the
.\" output yourself in some meaningful fashion.
-.ie \nF \{\
-. de IX
-. tm Index:\\$1\t\\n%\t"\\$2"
+.\"
+.\" Avoid warning from groff about undefined register 'F'.
+.de IX
..
-. nr % 0
-. rr F
-.\}
-.el \{\
-. de IX
+.nr rF 0
+.if \n(.g .if rF .nr rF 1
+.if (\n(rF:(\n(.g==0)) \{
+. if \nF \{
+. de IX
+. tm Index:\\$1\t\\n%\t"\\$2"
..
+. if !\nF==2 \{
+. nr % 0
+. nr F 2
+. \}
+. \}
.\}
+.rr rF
.\"
.\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2).
.\" Fear. Run. Save yourself. No user-serviceable parts.
@@ -124,7 +133,7 @@
.\" ========================================================================
.\"
.IX Title "PHOTOALBUM 1"
-.TH PHOTOALBUM 1 "2014-05-13" "photoalbum 0.4.4" "User Commands"
+.TH PHOTOALBUM 1 "2014-07-01" "photoalbum 0.4.4" "User Commands"
.\" For nroff, turn off justification. Always turn off hyphenation; it makes
.\" way too many mistakes in technical documents.
.if n .ad l
@@ -163,7 +172,7 @@ Creates a Makefile and photoalbumrc in the current working directory.
.PP
It is possible to specify a custom rcfile path too.
.PP
-\fI\s-1HTML\s0 \s-1TEMPLATES\s0\fR
+\fI\s-1HTML TEMPLATES\s0\fR
.IX Subsection "HTML TEMPLATES"
.PP
Go to the templates directory and edit them as wished.
diff --git a/src/photoalbum.sh b/src/photoalbum.sh
index 82c086a..306090f 100755
--- a/src/photoalbum.sh
+++ b/src/photoalbum.sh
@@ -3,10 +3,10 @@
# photoalbum (c) 2011 - 2014 by Paul C. Buetow
# http://photoalbum.buetow.org
-declare -r VERSION='PHOTOALBUMVERSION'
-declare -r DEFAULTRC=/etc/default/photoalbum
-declare -r ARG1="${1}" ; shift
-declare RC_FILE="${1}" ; shift
+readonly VERSION='PHOTOALBUMVERSION'
+readonly DEFAULTRC=/etc/default/photoalbum
+readonly ARG1="${1}" ; shift
+declare RC_FILE="${1}" ; shift
function usage {
cat - <<USAGE >&2
@@ -29,7 +29,7 @@ MAKEFILE
function tarball {
# Cleanup tarball from prev run if any
find "${DIST_DIR}" -maxdepth 1 -type f -name \*.tar -delete
- declare -r base=$(basename "${INCOMING_DIR}")
+ readonly base=$(basename "${INCOMING_DIR}")
echo "Creating tarball ${DIST_DIR}/${tarball_name} from ${INCOMING_DIR}"
cd $(dirname "${INCOMING_DIR}")
@@ -37,10 +37,10 @@ function tarball {
cd - &>/dev/null
}
-function template {
- declare -r template=${1} ; shift
- declare -r html=${1} ; shift
- declare -r dist_html="${DIST_DIR}/${html_dir}"
+function template() {
+ readonly template=${1} ; shift
+ readonly html=${1} ; shift
+ readonly dist_html="${DIST_DIR}/${html_dir}"
# Creating ${dist_html}/${html}.html from ${template}.tmpl
[ ! -d "${dist_html}" ] && mkdir -p "${dist_html}"
@@ -184,9 +184,9 @@ function generate {
fi
if [ "${TARBALL_INCLUDE}" = yes ]; then
- declare -r base=$(basename "${INCOMING_DIR}")
- declare -r now=$(date +'%Y-%m-%d-%H%M%S')
- declare -r tarball_name="${base}-${now}${TARBALL_SUFFIX}"
+ readonly base=$(basename "${INCOMING_DIR}")
+ readonly now=$(date +'%Y-%m-%d-%H%M%S')
+ readonly tarball_name="${base}-${now}${TARBALL_SUFFIX}"
fi
test ! -d "${DIST_DIR}/photos" && mkdir -p "${DIST_DIR}/photos"