Update to version 0.4.2.
This commit is contained in:
parent
79da2c7f03
commit
3389a23e58
9
qsgen2
9
qsgen2
@ -16,7 +16,7 @@
|
|||||||
###############################################################################
|
###############################################################################
|
||||||
###############################################################################
|
###############################################################################
|
||||||
|
|
||||||
VERSION="0.4.1" # Mon-2024-02-19
|
VERSION="0.4.2" # Thu-2024-02-22
|
||||||
QSGEN="Quick Site Generator 2"
|
QSGEN="Quick Site Generator 2"
|
||||||
|
|
||||||
# Set to true or false
|
# Set to true or false
|
||||||
@ -915,7 +915,7 @@ function _sitemap() {
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# Check if sitemap is set to true and if there are updated Blogs or Pages before updating the sitemap.xml file.
|
# Check if sitemap is set to true and if there are updated Blogs or Pages before updating the sitemap.xml file.
|
||||||
if [[ ${sitemap} == "true" ]] && ( [[ ${new_updated_blogs} == "true" ]] || [[ ${new_updated_pages} == "true" ]] ) || [[ ${sitemap_force} == "true" ]]; then
|
if ([[ ${sitemap} == "true" ]] && ( [[ ${new_updated_blogs} == "true" ]] || [[ ${new_updated_pages} == "true" ]] )) || [[ ${sitemap_force} == "true" ]]; then
|
||||||
|
|
||||||
setopt extendedglob
|
setopt extendedglob
|
||||||
|
|
||||||
@ -929,7 +929,6 @@ function _sitemap() {
|
|||||||
local sitemap_page="${www_root}/${p_file}"
|
local sitemap_page="${www_root}/${p_file}"
|
||||||
|
|
||||||
# Find all HTML files and store them in an array
|
# Find all HTML files and store them in an array
|
||||||
# local -a html_files=("${(@f)$(find "${www_root}" -type f -name "*.html")}")
|
|
||||||
builtin cd ${config[site_root]}
|
builtin cd ${config[site_root]}
|
||||||
local -a html_files=(**/[a-z]*.html(.))
|
local -a html_files=(**/[a-z]*.html(.))
|
||||||
local -a blog_files=()
|
local -a blog_files=()
|
||||||
@ -1002,8 +1001,6 @@ function _sitemap() {
|
|||||||
|
|
||||||
if (${debug}); then _msg debug "${0:t}_msg_2" " ${sitemap_file}"; fi
|
if (${debug}); then _msg debug "${0:t}_msg_2" " ${sitemap_file}"; fi
|
||||||
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Start of the XML file for the main sitemap
|
# Start of the XML file for the main sitemap
|
||||||
echo '<?xml version="1.0" encoding="UTF-8"?>' > "${sitemap_file}"
|
echo '<?xml version="1.0" encoding="UTF-8"?>' > "${sitemap_file}"
|
||||||
echo "<sitemapindex xmlns=\"http://www.sitemaps.org/schemas/sitemap/0.9\">" >> "${sitemap_file}"
|
echo "<sitemapindex xmlns=\"http://www.sitemaps.org/schemas/sitemap/0.9\">" >> "${sitemap_file}"
|
||||||
@ -1028,6 +1025,8 @@ function _sitemap() {
|
|||||||
|
|
||||||
builtin cd ${config[project_root]}
|
builtin cd ${config[project_root]}
|
||||||
|
|
||||||
|
fi
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function _link() {
|
function _link() {
|
||||||
|
Loading…
Reference in New Issue
Block a user