core-nlg
core-nlg copied to clipboard
Date function missing
We should add a "nlg_date" function, witch have default behaviors depending on language
Maybe we should add something like this:
if platform.system() == "Windows": date_format = "%A %#d %B %Y" locale.setlocale(locale.LC_TIME, 'fr') else: date_format = "%A %-d %B %Y" locale.setlocale(locale.LC_TIME, 'fr_FR.utf8')
day, month, year = (int(x) for x in date.split('/')) date = datetime.date(year, month, day)
I think it's more about changing the format of a date (from the input for example) than getting the system date. But maybe we can have both.