qsgen2: More cleaning up tabs and spaces

This commit is contained in:
Stig-Ørjan Smelror 2024-02-05 21:19:22 +01:00
parent 535a5ec0b8
commit 28d26040a4

12
qsgen2
View File

@ -161,6 +161,7 @@ function _msg() {
echo "${2}"
;;
esac
}
case ${1} in
@ -220,6 +221,7 @@ export blogdate=$(strftime "%a-%Y-%b-%d")
# Let's create arrays of all the files we'll be working on
function _list_pages() {
if [[ ${globaldebug} == "true" ]]; then
local debug=true
else
@ -248,9 +250,11 @@ function _list_pages() {
pages_file_array+=("$file")
done
fi
}
function _list_blogs() {
if [[ ${globaldebug} == "true" ]]; then
local debug=true
else
@ -274,16 +278,19 @@ function _list_blogs() {
export no_blogs_found=true
return
else
for file in "${blog_files[@]}"; do
for file in "${blog_files[@]}"
do
if ${debug}; then _msg debug "_list_blogs: Adding file to array: $file"; fi
blogs_file_array+=("$file")
done
fi
}
# BLOG CACHE
function _blog_cache() {
if [[ ${globaldebug} == "true" ]]; then
local debug=true
else
@ -332,12 +339,14 @@ function _blog_cache() {
for name in "${(@k)blog_cache}"; do
echo "$name:${blog_cache[$name]}" >> "$blog_cache_file"
done
}
# PAGES CACHE
# Returns the array pages_array()
function _pages_cache() {
if [[ ${globaldebug} == "true" ]]; then
local debug=true
else
@ -387,6 +396,7 @@ function _pages_cache() {
for name in "${(@k)pages_cache}"; do
echo "$name:${pages_cache[$name]}" >> "$pages_cache_file"
done
}
function _last_updated() {