Skip to content

Alcheri/WorldTime

 
 

Repository files navigation

Limnoria plugin for WorldTime

Tests Lint CodeQL Python Black Limnoria

Retrieve current time and time zone information for various locations.

Forked from reticulatingspline/WorldTime.

Install

Go into your Limnoria plugin dir, usually ~/runbot/plugins and run:

GitHub CLI: gh repo clone Alcheri/WorldTime or SSH: git clone git@github.com:Alcheri/WorldTime.git

To install additional requirements, run from /plugins/WorldTime folder:

pip install --upgrade -r requirements.txt

Next, load the plugin:

/msg bot load WorldTime

Enable Google Geocoding and Time Zone APIs. Set your API Key using the command below

  • config plugins.worldtime.mapsapikey <your_key_here

  • config channel #channel plugins.WorldTime.cooldownSeconds 5

    Sets the per-user worldtime lookup cooldown for the channel.

  • config plugins.WorldTime.maxResponseBytes 262144

    Sets the maximum Google API response size WorldTime will read.

Security notes:

  • --nick lookups are public and use locations that users have stored with set.
  • Stored locations and direct lookup locations are capped and sanitised before use.
  • Replies preserve intentional IRC formatting while stripping unsafe control characters.

Example Usage

<spline> @worldtime New York, NY
<myybot> New York, NY, USA :: Current local time is: Sat, 09:38 (Eastern Daylight Time)
<spline> @worldtime 90210
<myybot> Beverly Hills, CA 90210, USA :: Current local time is: Sat, 06:38 (Pacific Daylight Time)

Add an alias to your bot for ease of use.

aka add [--channel <#channel>] <name> <command>

@wt set [location] -- Sets your current ident@host to [location]

@wt unset -- Removes your current ident@host

Licensing

This project contains code originally published under the MIT Licence by the upstream author. The original licence text is preserved verbatim in LICENSE.txt as required by the MIT Licence.

All modifications, additions, and ongoing maintenance performed by Barry Suridge are licensed under the terms described in LICENCE.md.

In summary:

  • LICENSE.txt — original upstream MIT Licence (unchanged)
  • LICENCE.md — licence applying to Barry Suridge’s contributions

About

A Supybot / Limnoria plugin to display time in various cities

Topics

Resources

Contributing

Security policy

Stars

Watchers

Forks

Used by

Contributors

Languages