Merge pull request #100 from martinbydefault/gh-pages

added prompt to choose title, tag is added to allowed-tags
This commit is contained in:
Tom Johnson 2017-08-09 16:22:33 -07:00 committed by GitHub
commit f81ee342a7
2 changed files with 9 additions and 2 deletions

View File

@ -1,3 +1,6 @@
# Note:
# If you are using the createtag script, don't leave an blank line at the end of this file.
# In other words, the last line must be the last tag in the allowed-tags list.
allowed-tags: allowed-tags:
- getting_started - getting_started
- content_types - content_types
@ -9,4 +12,4 @@ allowed-tags:
- collaboration - collaboration
- news - news
- troubleshooting - troubleshooting
- mobile - mobile

View File

@ -22,10 +22,12 @@ if [ -d "${TAGDIR}" ]; then
echo "Creating tag(s) for ${tags}" echo "Creating tag(s) for ${tags}"
for tag in ${tags}; do for tag in ${tags}; do
echo "Title for $tag:"
read title
# Cannot indent here string. # Cannot indent here string.
cat <<EOF >"${TAGDIR}/tag_${tag}.md" cat <<EOF >"${TAGDIR}/tag_${tag}.md"
--- ---
title: "${tag} Posts" title: "${title}"
tagName: ${tag} tagName: ${tag}
search: exclude search: exclude
permalink: tag_${tag}.html permalink: tag_${tag}.html
@ -39,6 +41,8 @@ folder: tags
{% include links.html %} {% include links.html %}
EOF EOF
echo " - ${tag}" >> _data/tags.yml
done done
else else