poetaman / arttime

arttime is a CLI application that blends beauty of ASCII / text art with functionality of clock / timer / pattern-based time manager in terminal ⏰
Other
938 stars 15 forks source link

24h clock styling #15

Closed PrtmPhlp closed 2 years ago

PrtmPhlp commented 2 years ago

I'm from Germany and here the time is 24h based. Would love a future Feature, where you can toggle between the 12 and 24 hour system. (Maybe directly in the "set or reset timezone" menu)

poetaman commented 2 years ago

That would be a good feature to have, will definitely add that, perhaps coming week if I get time.

poetaman commented 2 years ago

@PrtmPhlp @cjk I have pushed the change in main branch. Pull and run install.sh again if you installed using method 2) or just copy paste and run the simple installer again (it automatically pulls main branch and merges) if you used install method 1). https://github.com/reportaman/arttime#installation

There are 2 changes in UI:

  1. A CLI new option --hours can be provided while invoking arttime with value 24 or 12 (default)*
  2. A new keybinding f is added to toggle between 12 and 24 hour formats. Pressing f quickly toggles all times shown by arttime to one of the formats.

* I would recommend to set alias: alias arttime="arttime --hours 24" for those who want 24 hours by default. In future arttime might parse user's locale to find whether they want 12 hour or 24 hour format if there is a compelling reason...

PrtmPhlp commented 2 years ago

Thank you so much. Works great.