mirror of
https://git.rtems.org/rtems-docs/
synced 2025-05-15 05:57:08 +08:00
conf.py: Fix build_date() to append correct suffix on all days.
This commit is contained in:
parent
7193f09294
commit
876035b7bd
@ -8,10 +8,16 @@ def build_date():
|
||||
now = datetime.date.today()
|
||||
m = now.strftime('%b')
|
||||
y = now.strftime('%Y')
|
||||
if now.day % 10 == 1:
|
||||
if now.day == 11:
|
||||
s = 'th'
|
||||
elif now.day % 10 == 1:
|
||||
s = 'st'
|
||||
elif now.day == 12:
|
||||
s = 'th'
|
||||
elif now.day % 10 == 2:
|
||||
s = 'nd'
|
||||
elif now.day == 13:
|
||||
s = 'th'
|
||||
elif now.day == 3:
|
||||
s = 'rd'
|
||||
else:
|
||||
|
Loading…
x
Reference in New Issue
Block a user