script for date with ordinal suffixes
This commit is contained in:
parent
52a42447ca
commit
d737c49900
1 changed files with 10 additions and 0 deletions
10
config/hypr/scripts/date.sh
Normal file
10
config/hypr/scripts/date.sh
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
#!/bin/sh
|
||||||
|
DaySuffix() {
|
||||||
|
case `date +%e` in
|
||||||
|
1|21|31) echo "st";;
|
||||||
|
2|22) echo "nd";;
|
||||||
|
3|23) echo "rd";;
|
||||||
|
*) echo "th";;
|
||||||
|
esac
|
||||||
|
}
|
||||||
|
date "+%A, %e`DaySuffix` %B %Y"
|
Loading…
Reference in a new issue