diff --git a/Docs/.gitignore b/Docs/.gitignore new file mode 100644 index 0000000..f40fbd8 --- /dev/null +++ b/Docs/.gitignore @@ -0,0 +1,5 @@ +_site +.sass-cache +.jekyll-cache +.jekyll-metadata +vendor diff --git a/Docs/Gemfile b/Docs/Gemfile new file mode 100644 index 0000000..35d6a52 --- /dev/null +++ b/Docs/Gemfile @@ -0,0 +1,4 @@ +source "https://rubygems.org" +gem "jekyll", "~> 4.3.2" +gem "jekyll-remote-theme" +gem "jekyll-seo-tag" diff --git a/Docs/Gemfile.lock b/Docs/Gemfile.lock new file mode 100644 index 0000000..43cb228 --- /dev/null +++ b/Docs/Gemfile.lock @@ -0,0 +1,82 @@ +GEM + remote: https://rubygems.org/ + specs: + addressable (2.8.1) + public_suffix (>= 2.0.2, < 6.0) + colorator (1.1.0) + concurrent-ruby (1.1.10) + em-websocket (0.5.3) + eventmachine (>= 0.12.9) + http_parser.rb (~> 0) + eventmachine (1.2.7) + ffi (1.15.5) + forwardable-extended (2.6.0) + google-protobuf (3.21.12-x86_64-linux) + http_parser.rb (0.8.0) + i18n (1.12.0) + concurrent-ruby (~> 1.0) + jekyll (4.3.2) + addressable (~> 2.4) + colorator (~> 1.0) + em-websocket (~> 0.5) + i18n (~> 1.0) + jekyll-sass-converter (>= 2.0, < 4.0) + jekyll-watch (~> 2.0) + kramdown (~> 2.3, >= 2.3.1) + kramdown-parser-gfm (~> 1.0) + liquid (~> 4.0) + mercenary (>= 0.3.6, < 0.5) + pathutil (~> 0.9) + rouge (>= 3.0, < 5.0) + safe_yaml (~> 1.0) + terminal-table (>= 1.8, < 4.0) + webrick (~> 1.7) + jekyll-remote-theme (0.4.3) + addressable (~> 2.0) + jekyll (>= 3.5, < 5.0) + jekyll-sass-converter (>= 1.0, <= 3.0.0, != 2.0.0) + rubyzip (>= 1.3.0, < 3.0) + jekyll-sass-converter (3.0.0) + sass-embedded (~> 1.54) + jekyll-seo-tag (2.8.0) + jekyll (>= 3.8, < 5.0) + jekyll-watch (2.2.1) + listen (~> 3.0) + kramdown (2.4.0) + rexml + kramdown-parser-gfm (1.1.0) + kramdown (~> 2.0) + liquid (4.0.4) + listen (3.8.0) + rb-fsevent (~> 0.10, >= 0.10.3) + rb-inotify (~> 0.9, >= 0.9.10) + mercenary (0.4.0) + pathutil (0.16.2) + forwardable-extended (~> 2.6) + public_suffix (5.0.1) + rake (13.0.6) + rb-fsevent (0.11.2) + rb-inotify (0.10.1) + ffi (~> 1.0) + rexml (3.2.5) + rouge (4.0.1) + rubyzip (2.3.2) + safe_yaml (1.0.5) + sass-embedded (1.57.1) + google-protobuf (~> 3.21) + rake (>= 10.0.0) + terminal-table (3.0.2) + unicode-display_width (>= 1.1.1, < 3) + unicode-display_width (2.4.2) + webrick (1.7.0) + +PLATFORMS + x86_64-linux + +DEPENDENCIES + jekyll (~> 4.3.2) + jekyll-remote-theme + jekyll-seo-tag + +BUNDLED WITH + 2.4.5 diff --git a/Docs/_config.yml b/Docs/_config.yml new file mode 100644 index 0000000..9d2e9c1 --- /dev/null +++ b/Docs/_config.yml @@ -0,0 +1,25 @@ +# https://github.com/BDHU/minimalist +title: World Time +description: A social time zone reference tool! +logo: /wt-mid.png +show_downloads: false +remote_theme: BDHU/minimalist +color-scheme: dark + +plugins: + - jekyll-remote-theme + +# https://icon-sets.iconify.design/ +sidebar: + - name: Invite the bot + icon: + link: https://discord.com/api/oauth2/authorize?client_id=447266583459528715&permissions=16384&scope=bot%20applications.commands + - name: Official server + icon: + link: https://discord.gg/JCRyFk7 + - name: GitHub + icon: + link: https://github.com/NoiTheCat/WorldTime + - name: Support me on Ko-fi + icon: + link: https://ko-fi.com/noithecat \ No newline at end of file diff --git a/Docs/example.png b/Docs/example.png new file mode 100644 index 0000000..2c36637 Binary files /dev/null and b/Docs/example.png differ diff --git a/Docs/index.md b/Docs/index.md new file mode 100644 index 0000000..c49d451 --- /dev/null +++ b/Docs/index.md @@ -0,0 +1,34 @@ +--- +layout: default +title: Documentation +--- +# World Time +World Time is a simple utility bot, providing users with a quick way to check the current time and day for the users in your server. + +### Getting started +Invite the bot via the link on the sidebar. Once invited, the bot can be used through its commands any time it is needed. + +For a list of commands, see its `/help` command. + +### Why would I even want to use this? +Here's a hypothetical scenario: + +Imagine that you are one user amongst many in a large community, its other users scattered all around the world. Though you feel a yearning for conversation, spurred on by a sense of boredom or unfulfillment, few seem to be available. Their statuses tease their potential existence, but they have been idle for quite some time. Surely they're around? + +You are a courteous one, and you do not make assumptions. The concept of time zones crosses the front of your mind; different places around the world being subject to hours different from yours. You even consider for a moment the uncomfortable notion that others may have lives beyond the reaches of the internet. All of this ultimately lead to one important question burning at the front of your mind: Is this even a good time? + +![Example output](example.png) + +Oh. Well... Hm. + +### Supporting the bot +World Time is provided for free, period. No paywalled features, subscriptions, or monetization insentices. World Time is an independent hobby project done in my spare time, and all costs associated with it come out of my pocket. My only interest is to provide something that I hope others find as useful as I do. + +That said, this bot has proven to be far more popular than I ever anticipated, and keeping things running has occasionally strained me both financially and time-wise. If you'd like, please consider pitching in a bit to cover my recurring costs by checking out my Ko-fi page on the sidebar. + +### Privacy and Security +This bot collects and stores only information necessary for its operation, in this case being user, server, and role IDs. As little information is stored as possible and access to the database is strongly restricted through proper security practices. + +Time zones are not shared between servers *by design*, for those preferring to be selective about where they want their region known. Users must set their times in each individual server. + +Any questions and concerns regarding data privacy, security, and retention may be sent to the bot author via the support server or by opening an issue on GitHub. \ No newline at end of file diff --git a/Docs/wt-mid.png b/Docs/wt-mid.png new file mode 100644 index 0000000..48ed666 Binary files /dev/null and b/Docs/wt-mid.png differ diff --git a/Readme.md b/Readme.md index 027cedd..de416fe 100644 --- a/Readme.md +++ b/Readme.md @@ -1,27 +1,37 @@ # World Time +A social time zone reference tool! -* Info: https://discord.bots.gg/bots/447266583459528715 +[![ko-fi](https://ko-fi.com/img/githubbutton_sm.svg)](https://ko-fi.com/J3J65TW2E) -## A social time zone reference tool! -World Time is a simple bot that acts as a quick reference for checking the current time and day for the users in your server. To use it is as simple as having your users individually add their time zone, and anyone is then free to look up the full list of current times, or those of individual users. +#### Documentation, help, resources +* [Main website, user documentation](https://noithecat.dev/bots/WorldTime) +* [Official server](https://discord.gg/JCRyFk7) -#### Why might this be useful? -Imagine that you find yourself amongst a large online community, its users scattered across the land. You feel a yearning for conversation, spurred on by a sense of boredom or unfulfillment, but none seem to be available. Many people appear on the sidebar, but they have been idle for quite some time. Surely they're around, though? +#### Running your own instance +You need: +* .NET 6 (https://dotnet.microsoft.com/en-us/) +* PostgreSQL (https://www.postgresql.org/) +* EF Core tools (https://learn.microsoft.com/en-us/ef/core/get-started/overview/install#get-the-entity-framework-core-tools) +* A Discord bot token (https://discord.com/developers/applications) -You are a courteous one, and you do not make assumptions. You recall the concept of time zones, of different places around the world being subject to hours different from yours no matter the moment. You consider the uncomfortable idea that these people might also have lives of their own which do not often involve this chat platform. All these realizations ultimately lead to one important question: Is this even a good time for them? +Get your bot token and set up your database user and schema, then create a JSON file containing the following: +```jsonc +{ + "BotToken": "your bot token here", + "SqlHost": "localhost", // optional + "SqlDatabase": "worldtime", // optional + "SqlUser": "worldtime", // required + "SqlPassword": "mypassword" // required; no other authentication methods are currently supported +} +``` -Perhaps this bot can offer some enlightenment. What you do with this information is up to you. +Then run the following commands: +```sh +$ dotnet restore +$ dotnet ef database update -- -c path/to/config.json +``` -#### Support the bot -World Time is and shall remain fully free to use. I have no plans to hide any new or existing features behind pay-only, premium features. This is an independent hobby project and all costs associated with it come out of my pocket. - -This bot has had a far greater response than I've ever expected, and at this point I find it difficult to pay for the server it runs on as its resource needs grow. I would greatly appreciate if you consider pitching in a little bit to cover my recurring costs by checking out my Ko-fi page: https://ko-fi.com/noithecat. - -#### Support, Privacy and Security -The support server for my bots can be accessed via the given link: https://discord.gg/JCRyFk7. A small group of volunteers who are willing to answer questions are able to help you if you have any questions. - -This bot collects and stores only information necessary for its operation, including user, server, and role IDs. On occasion, data for server members not seen in some time (at least 180 days) may be manually removed by the bot owner. - -Time zones are not shared between servers that this same bot may be in. This is *by design*, for those preferring to share this information with only certain communities instead of automatically sharing it to all of them. Users must register their time zone information onto every server they share with the bot for the servers they wish for it to be known in. - -Any questions and concerns regarding data and security may be sent to the bot author via the support server or GitHub. \ No newline at end of file +And finally, to run the bot: +``` +$ dotnet run -c Release -- -c path/to/config.json +``` \ No newline at end of file diff --git a/WorldTime.csproj b/WorldTime.csproj index 23fd9cf..3da1c84 100644 --- a/WorldTime.csproj +++ b/WorldTime.csproj @@ -26,4 +26,8 @@ + + Docs/**;$(DefaultItemExcludes) + +