Skip to content

Commit

Permalink
chore(global): switch to tsx + npm for that
Browse files Browse the repository at this point in the history
  • Loading branch information
ajhalili2006 committed Jan 9, 2025
1 parent 97b3168 commit 039a1a9
Show file tree
Hide file tree
Showing 8 changed files with 3,507 additions and 4,653 deletions.
5 changes: 5 additions & 0 deletions .vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"recommendations": [
"arcanis.vscode-zipfs"
]
}
26 changes: 26 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
{
"search.exclude": {
"**/.yarn": true,
"**/.pnp.*": true
},
"typescript.tsdk": "node_modules/typescript/lib",
"dotenv.enableAutocloaking": false,
"emojisense.languages": {
"markdown": true,
"plaintext": {
"markupCompletionsEnabled": true,
"emojiDecoratorsEnabled": false
},
"scminput": true,
"git-commit": true,
"typescript": {
"markupCompletionsEnabled": true,
"unicodeCompletionsEnabled": true
}
},
// required in vscode-eslint < v3.0.10 only
"eslint.useFlatConfig": true,
"conventionalCommits.scopes": [
"global"
]
}
934 changes: 0 additions & 934 deletions .yarn/releases/yarn-4.5.3.cjs

This file was deleted.

2 changes: 0 additions & 2 deletions .yarnrc.yml

This file was deleted.

59 changes: 57 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,57 @@
# hcb-explorer-discord
Explore HCB organizations' transactions and more on Discord (currently with transparency mode)
# HCB Explorer on Discord

It's the Discord edition of [HCB Stalker], built with [Discord.js] library,
running on Hack Club Nest by @ajhalili2006. Most HCB API endpoints are accessible via
slash commands for discoverability and to match the Slack experience.

[HCB Stalker]: https://github.com/Ssmidge/HCBFetcher
[Discord.js]: https://discord.js.org

## Bot features

* Ongoing
* Port HCB Stalker Slack slash commands to Discord
* Postgres-based DB presistence (via Prisma ORM) for org slug caching and stuff
* Some basic API server for discoverability and maybe docs via [Hono](https://hono.dev)
* Planned
* Authenicated calls to HCB v4 API via OAuth (once the docs are available)
* HCB organization activity real-time monitoring over Discord-compatible webhooks (aka logging)
* Zulip support?!?

## Installation

### Using the hosted instance

Just install the app into your Discord account or server
by [clicking here](https://hcb-explorer-discordbot.ajhalili2006.hackclub.app/install).

### Self-hosting

Running the bot on your own requires a recent Node.js
LTS release and a Discord app ID + bot token ready.

1. Clone the repository and install dependencies:

```sh
git clone https://github.com/recaptime-dev/hcb-explorer-discord && cd hcb-explorer-discord
yarn install
```

2. Reset the `.env.production` file by blanking it's contents and using `dotenvx` to add your Discord bot token:

```sh
# see https://superuser.com/questions/90008/how-to-clear-the-contents-of-a-file-from-the-command-line for
# more ways to clear a file's contents
cat /dev/null > .env.production

# required
yarn dotenvx set -f .env.production -- DISCORD_BOT_TOKEN <your-bot-token>
yarn dotenvx set -f .env.production -- DISCORD_BOT_APP_ID <your-app-id>

## optional
yarn dotenvx set -f .env.production -- SENTRY_DSN <your-sentry-dsn>
```

## License

MPL
Loading

0 comments on commit 039a1a9

Please sign in to comment.