优化代码结构,更改部分常量命名
本来是除夕过个年,打开邮箱一看,又有人提了我去年就已经修复的问题,有点感慨(?) 于是我再次打开这个项目,在今年的除夕更新如下内容:
- 把原本放在
__init__.py的主类全部移入了main.py中,并在__init__.py里加了引用和版本字符串 - 更新翻译,把原本的
Chinese New Year(CHINESENEWYEAR)和Chinese Year Code(CHINESEYEARCODE)俩常量的翻译改为Lunar New Year和Lunar Year Code即LUNARNEWYEAR, LUNARYEARCODE - 使用
Blcak格式化了文档,constants.py除外,主要是那玩意格式化完了之后更丑了…… - 没了,格式化一下 README 算么[手动狗头]
=========
It is when I want to open some games to play and a notifacation from E-Mail disturb me that a issue has been turned out that is what I have repaired last year the same date. So I decided to open this repo again and do some changes...
- Moved the classes originally in
__init__.pyintomain.pyand add__version__and__all__into__init__.py. - Updated the translation.
Chinese New Year(CHINESENEWYEAR),Chinese Year Code(CHINESEYEARCODE)->Lunar New YearLunar Year Code(LUNARNEWYEAR, LUNARYEARCODE) - Formatted the codes via
Blcak, exceptconstants.pyfor it may be more ugly after do the formatting. - Also formatted README.
刚刚新增了一些代码,主要是把生肖常量、天干地支常量、中文数字常量转移到了constants.py里面去,然后新增了一个__format__方法的覆写,主要解决了 #2 的ISSUE,顺带把today和from_datetime改为了类方法。
您有考虑fork一份换个包名上传到pypi吗,看起来原作者可能没有时间继续维护了:(
您有考虑fork一份换个包名上传到pypi吗,看起来原作者可能没有时间继续维护了:(
已经完成了一个新的农历日期库,并上传了pypi,叫做zhDateTime。
因为我不喜欢GPLv3,所以就自己把农历日期时间重写了一遍,采用协议MPL2.0,用法可以参阅zhDateTime
仓库地址https://gitee.com/EillesWan/zhDateTime