remove leading zero for day

This commit is contained in:
Xi Ruoyao 2021-04-07 01:13:48 +08:00
parent 7e80757c0d
commit 6b505dabb8
No known key found for this signature in database
GPG Key ID: D95E4716CCBB34DC

View File

@ -19,7 +19,7 @@ short_date=$(date --date "$commit_date" "+%Y%m%d")
year=$(date --date "$commit_date" "+%Y")
month=$(date --date "$commit_date" "+%B")
month_digit=$(date --date "$commit_date" "+%m")
day=$(date --date "$commit_date" "+%d")
day=$(date --date "$commit_date" "+%d" | sed 's@^0@@')
case $day in
"1" | "21" | "31" ) suffix="st";;