polyglossia
polyglossia copied to clipboard
Offer a \today-like command with month and year only
Sometimes, people want to refer to the current month - which means the month-within-year and the year. \today
doesn't cut it, and since the ordering/layout of month-cum-year differs between languages, users are a bit stuck. It would be nice if we have a \todayasmonth
or some similar command which produces this.
See also this SO question.
As to the SO question: AFAICS this doesn't work with babel
either, and I think the reason is that datetime2-hebrew
is not really maintained and probably not fully working. Independent of whether polyglossia
implements an own way of doing that, it would be good if someone took up maintenance of datetime2-hebrew
, as this package can do so much more we never can provide.
Looking at it again, I think this should be fixed in datetime2-hebrew
itself.
@jspitz : You could file it as an issue there before closing it here...
You can do that, it's your request. I suppose the answer will be: somebody needs to take maintenance for datetime2-hebrew.
For the record, something like the attached would need to be done in datetime2-hebrew
to make showdayofmonth
and showyear
work with polyglossia
. As I do not read Hebrew, I am not sure the output is entirely correct, but this could be adopted easily by someone in the know.
You can test this (both with calendar=hebrew
and calendar=gregorian
in polyglossia Hebrew) and propose it to Nicola (the datetime2 author and current datetime2-hebrew maintainer) if you want.
datetime2-hebrew.ldf.txt (I have added the txt suffix only to get it accepted by the tracker. Remove it for testing.)
This one should also work for babel
(untested):
datetime2-hebrew.ldf.txt
@nlct I just want to bring this to your attention.
Would you be interested in integrating this to datetime2-hebrew
? As said, I cannot take over maintenance, and as I do not speak Hebrew, this would certainly need careful audit and testing. But maybe @eyalroz is willing to at least test and give advice on correctness of output. I take it that a range of other things would need to be done to get datetime2-hebrew
on par with other language modules.
I'm sorry, I can't speak Hebrew, and I'm already behind on a major refactor of datatool
, so I certainly wouldn't have the time to look at it until after that work is completed.
Fair enough @nlct. Should you ever find the time and energy for it, you can come back to this ticket. Maybe a Hebrew user steps up in the meantime and takes care for the module.