Skip to content

Commit

Permalink
update_changelog II
Browse files Browse the repository at this point in the history
  • Loading branch information
tcharp38 committed Apr 23, 2024
1 parent c0afb7b commit f1cd549
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 14 deletions.
30 changes: 17 additions & 13 deletions .tools/update_changelog.sh
Original file line number Diff line number Diff line change
Expand Up @@ -37,24 +37,28 @@ do
continue # Continue until version updated
fi

# Anything but a version line
if [[ "${L}" != "## "* ]]; then
# Adding current version
# Version line
if [[ "${L}" == "## "* ]]; then
if [[ "${L}" == "## ${VERSION}"* ]]; then
echo "- Version is already correct in changelog. Doing nothing"
echo
rm ${TMP}
break
fi
echo "- Updating version to ${VERSION}"
echo "## ${VERSION}" >> ${TMP}
# Adding current line
echo "" >> ${TMP}
echo "${L}" >> ${TMP}
STEP=2 # Copy rest of the file
continue
fi

# Version line:
if [[ "${L}" == "## ${VERSION}"* ]]; then
echo "- There is already correct version in changelog. Doing nothing"
echo
rm ${TMP}
break
fi
# Anything but a version line
echo "- Adding version ${VERSION}"
# Adding current version
echo "## ${VERSION}" >> ${TMP}
# Adding current line
echo "" >> ${TMP}
echo "${L}" >> ${TMP}
STEP=2 # Copy rest of the file

# if [[ "${L}" == "- "* ]] || [[ "${L}" == " "* ]]; then
# # It's a list (starts with '- ') or something starting with space
Expand Down
1 change: 0 additions & 1 deletion docs/fr_FR/Changelog.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
# Plugin 'Abeille': changeLog


## 240423-BETA-3

**Mise-à-jour de modèles**
Expand Down

0 comments on commit f1cd549

Please sign in to comment.