Skip to content

Commit 47ef9cb

Browse files
versecafeADKaster
authored andcommitted
huge overhaul for Ladybird server and project
1 parent 4d1df7a commit 47ef9cb

35 files changed

+1812
-2540
lines changed

.github/codeql/configuration.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name : CodeQL Configuration
1+
name: CodeQL Configuration
22

33
paths:
4-
- './src'
4+
- "./src"

.github/dependabot.yml

Lines changed: 0 additions & 22 deletions
This file was deleted.

.github/workflows/codeql.yml

Lines changed: 11 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,31 +1,30 @@
11
name: "CodeQL Static Analysis"
22

3-
on:
3+
on:
44
push:
55
branches: [master]
66
pull_request:
77
branches: [main]
88

99
jobs:
1010
CodeQL-Build:
11-
1211
# CodeQL runs on ubuntu-latest and windows-latest
1312
runs-on: ubuntu-latest
1413
permissions:
1514
security-events: write
1615
actions: read
1716

1817
steps:
19-
- name: Checkout repository
20-
uses: actions/checkout@v4
18+
- name: Checkout repository
19+
uses: actions/checkout@v4
2120

22-
- name: Initialize CodeQL
23-
uses: github/codeql-action/init@v3
24-
with:
25-
config-file: ./.github/codeql/configuration.yml
21+
- name: Initialize CodeQL
22+
uses: github/codeql-action/init@v3
23+
with:
24+
config-file: ./.github/codeql/configuration.yml
2625

27-
- name: Autobuild
28-
uses: github/codeql-action/autobuild@v3
26+
- name: Autobuild
27+
uses: github/codeql-action/autobuild@v3
2928

30-
- name: Perform CodeQL Analysis
31-
uses: github/codeql-action/analyze@v3
29+
- name: Perform CodeQL Analysis
30+
uses: github/codeql-action/analyze@v3

.pre-commit-config.yaml

Lines changed: 0 additions & 33 deletions
This file was deleted.

.prettierrc

Lines changed: 0 additions & 13 deletions
This file was deleted.

README.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,13 +17,16 @@ $ bun start
1717

1818
To configure the bot for local development you simply need to drop your discord bot token and guild ID in an `.env` file at the root of this project.
1919
The contents should look something like:
20+
2021
```ini
2122
discord_token=<your-token-goes-here>
2223
guild_id=<your-guild-id-goes-here>
2324
```
25+
2426
See: https://www.writebots.com/discord-bot-token/
2527

2628
Now you can run `bun start:dev` and the bot will startup, and then restart as you save changes to the source files:
29+
2730
```
2831
❯ bun start:dev
2932
$ bun --watch ./src/index.ts
@@ -37,4 +40,3 @@ There are no tests yet, please help add some.
3740
### Credits
3841

3942
This was originally based off of the following discord bot template: https://github.com/MidasXIV/hive-greeter
40-

bun.lockb

-24.1 KB
Binary file not shown.

package.json

Lines changed: 53 additions & 69 deletions
Original file line numberDiff line numberDiff line change
@@ -1,71 +1,55 @@
11
{
2-
"name": "ladybird-bot",
3-
"version": "0.0.1",
4-
"description": "Ladybird Discord Bot",
5-
"main": "index.js",
6-
"license": "BSD-2-Clause",
7-
"engines": {
8-
"node": ">=16 <=18.17.1"
9-
},
10-
"scripts": {
11-
"lint": "eslint . --ext .ts",
12-
"lint-and-fix": "eslint . --ext .ts --fix",
13-
"start:dev": "bun --watch ./src/index.ts",
14-
"start": "bun ./src/index.ts",
15-
"test": "mocha -r ts-node/register tests/**/*.test.ts"
16-
},
17-
"nodemonConfig": {
18-
"watch": [
19-
"src"
20-
],
21-
"ext": ".ts,.js",
22-
"ignore": [],
23-
"exec": "ts-node --files ./src/index.ts"
24-
},
25-
"repository": {
26-
"type": "git",
27-
"url": "git+https://github.com/LadybirdBrowser/discord-bot.git"
28-
},
29-
"keywords": [
30-
"discord",
31-
"typescript",
32-
"bot",
33-
"ladybird",
34-
"serenityos"
35-
],
36-
"bugs": {
37-
"url": "https://github.com/LadybirdBrowser/discord-bot/issues"
38-
},
39-
"homepage": "https://github.com/LadybirdBrowser/discord-bot#readme",
40-
"devDependencies": {
41-
"@octokit/types": "^9.1.2",
42-
"@types/chai": "^4.3.4",
43-
"@types/mocha": "^10.0.1",
44-
"@typescript-eslint/eslint-plugin": "^5.59.9",
45-
"@typescript-eslint/parser": "^5.59.1",
46-
"chai": "^4.3.7",
47-
"eslint": "^8.39.0",
48-
"eslint-config-prettier": "^8.8.0",
49-
"eslint-plugin-prettier": "^4.2.1",
50-
"eslint-plugin-unused-imports": "^2.0.0",
51-
"mocha": "^10.2.0",
52-
"nodemon": "^2.0.22",
53-
"prettier": "^2.8.8",
54-
"ts-node": "^10.9.1"
55-
},
56-
"dependencies": {
57-
"@octokit/plugin-throttling": "^5.1.1",
58-
"@octokit/rest": "^19.0.7",
59-
"@types/node": "^18.16.3",
60-
"axios": "^1.4.0",
61-
"bufferutil": "^4.0.7",
62-
"discord.js": "^14.7.1",
63-
"dotenv": "^16.0.3",
64-
"mastodon": "^1.2.2",
65-
"octokit-plugin-create-pull-request": "^4.1.1",
66-
"rimraf": "^5.0.0",
67-
"typescript": "^5.0.4",
68-
"utf-8-validate": "^6.0.3",
69-
"zlib-sync": "^0.1.8"
70-
}
2+
"name": "ladybird-bot",
3+
"version": "0.1.0",
4+
"description": "Ladybird Discord Bot",
5+
"license": "BSD-2-Clause",
6+
"scripts": {
7+
"lint": "eslint . --ext .ts",
8+
"lint-and-fix": "eslint . --ext .ts --fix",
9+
"start:dev": "bun --watch ./src/index.ts",
10+
"start": "bun ./src/index.ts",
11+
"test": "bun test",
12+
"format": "prettier --write ."
13+
},
14+
"repository": {
15+
"type": "git",
16+
"url": "git+https://github.com/LadybirdBrowser/discord-bot.git"
17+
},
18+
"keywords": [
19+
"discord",
20+
"typescript",
21+
"bot",
22+
"ladybird",
23+
"serenityos"
24+
],
25+
"bugs": {
26+
"url": "https://github.com/LadybirdBrowser/discord-bot/issues"
27+
},
28+
"homepage": "https://github.com/LadybirdBrowser/discord-bot#readme",
29+
"devDependencies": {
30+
"@octokit/types": "^13.5.0",
31+
"@types/bun": "latest",
32+
"@typescript-eslint/eslint-plugin": "^7.15.0",
33+
"@typescript-eslint/parser": "^7.15.0",
34+
"eslint": "^8.39.0",
35+
"eslint-config-prettier": "^8.8.0",
36+
"eslint-plugin-prettier": "^5.1.3",
37+
"eslint-plugin-unused-imports": "^4.0.0",
38+
"prettier": "^3.3.2"
39+
},
40+
"dependencies": {
41+
"@octokit/plugin-throttling": "^9.3.0",
42+
"@octokit/rest": "^21.0.0",
43+
"axios": "^1.4.0",
44+
"bufferutil": "^4.0.7",
45+
"discord.js": "^14.15.3",
46+
"mastodon": "^1.2.2",
47+
"rimraf": "^5.0.0",
48+
"utf-8-validate": "^6.0.3",
49+
"zlib-sync": "^0.1.8",
50+
"zod": "^3.23.8"
51+
},
52+
"peerDependencies": {
53+
"typescript": "^5.5.3"
54+
}
7155
}

0 commit comments

Comments
 (0)