summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoradmin (centauri.fritz.box) <puppet@mx.buetow.org>2014-06-30 23:27:41 +0200
committeradmin (centauri.fritz.box) <puppet@mx.buetow.org>2014-06-30 23:27:41 +0200
commited42008333cb524bc21ecdee1c046f8211127c47 (patch)
treead74346f3026cd04235e5bbac0066a3f89315d46
parentaa811eea0552976ff378a96f154fb4951be1e1c5 (diff)
parent438bafad190d1e10ae961e8a7a2c039f93afcdad (diff)
Merge remote-tracking branch 'remotes/github/develop' into develop
-rwxr-xr-xsrc/photoalbum.sh22
1 files changed, 11 insertions, 11 deletions
diff --git a/src/photoalbum.sh b/src/photoalbum.sh
index a047339..2f7be9f 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}")
@@ -38,9 +38,9 @@ function tarball() {
}
function template() {
- declare -r template=${1} ; shift
- declare -r html=${1} ; shift
- declare -r dist_html="${DIST_DIR}/${html_dir}"
+ 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
scalephotos