https://github.com/devsheva/hn-telegram-bot
HackerNews Telegram Bot
https://github.com/devsheva/hn-telegram-bot
deno grammy hackernews telegram-bot typescript
Last synced: 7 months ago
JSON representation
HackerNews Telegram Bot
- Host: GitHub
- URL: https://github.com/devsheva/hn-telegram-bot
- Owner: devsheva
- Created: 2024-06-11T20:00:43.000Z (over 1 year ago)
- Default Branch: master
- Last Pushed: 2025-01-02T16:53:51.000Z (9 months ago)
- Last Synced: 2025-01-13T11:16:47.954Z (9 months ago)
- Topics: deno, grammy, hackernews, telegram-bot, typescript
- Language: TypeScript
- Homepage: https://t.me/HackerNewsTrackingBot
- Size: 366 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
Awesome Lists containing this project
README
# hn-telegram-bot

[](https://codecov.io/gh/devsheva/hn-telegram-bot)HackerNews Telegram Bot
## Usage
### Development
To develop in local just run `deno task dev` that will start in watch mode.
To update the changelog just run `git-cliff -o CHANGELOG.md`.### Testing
**Pass the necessary environment variables to run against test mode!**
- APP_ENV=test
- SUPABASE_KEY=your_key
- SUPABASE_SCHEMA=test
- SUPABASE_URL=your_urlPut all tests under this [folder](src/__tests__) and run `deno task test`, which will run test environment with Deno in watch mode.
You must pass at least the following environment variables to make testing work:
- APP_ENV
- SUPABASE_URL
- SUPABASE_KEY> Note: this is a temporary workaround until conversations plugin is fixed
When running tests on a composer that involves conversation, always add `await new Promise(r => setTimeout(r, 0))`, so it doesn't lead to
deno leaks due to sanitizers.### Tips
This project is made by mainly following BDD principles, so you should stick to it, you won't regret.
## Release
1. Open a Pull Request on `master` branch.
2. Tag version from local then push (adheres to `semver`)
3. Bump changelog with `git-cliff --bump`
4. Wait approval of PR, in case of merge it will be officially released.## Deployment
It's handled with GitHub Actions, with two [workflows](.github/workflows/):
- **deploy.yml**
- 3 jobs: test, coverage, deploy
- **update.yml**: external GH Action that acts like dependabot but for deno