Skip to content

Commit

Permalink
FIXUP
Browse files Browse the repository at this point in the history
  • Loading branch information
AndrewSisley committed Mar 27, 2023
1 parent 5bf54a9 commit c0ab822
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions tools/scripts/validate-conventional-style.sh
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ fi

CHECK_SPACE="${DESCRIPTION::1}"; # First character
CHECK_FIRST_UPPER_CASE="${DESCRIPTION:1:1}"; # Second character
CHECK_LAST_LOWER_CASE_OR_NUM="${DESCRIPTION: -1}"; # Last character
CHECK_ALPHA_NUM="${DESCRIPTION: -1}"; # Last character

# Validate that there is a space between the label and description.
if [ "${CHECK_SPACE}" != " " ]; then
Expand All @@ -81,8 +81,8 @@ if [[ "${CHECK_FIRST_UPPER_CASE}" != [A-Z] ]]; then
exit 7;
fi

# Validate that the last character is a lower case alphabet or a number character.
if [[ "${CHECK_LAST_LOWER_CASE_OR_NUM}" != [a-zA-Z0-9] ]]; then
# Validate that the last character is an alphabet or a number character.
if [[ "${CHECK_ALPHA_NUM}" != [a-zA-Z0-9] ]]; then
printf "Error: Last character is neither an alphabet nor a number.\n";
exit 8;
fi
Expand Down

0 comments on commit c0ab822

Please sign in to comment.