Skip to content

Commit 963eed9

Browse files
Merge branch 'development' into fix/post-message-sdk
# Conflicts: # .github/workflows/update-configuration.yml # .github/workflows/worker-deploy.yml # dist/index.js # manifest.json # package.json # src/handlers/query-wallet.ts # src/plugin.ts # tests/main.test.ts # wrangler.toml
2 parents a6b2c7f + 4438e2b commit 963eed9

30 files changed

+264
-122019
lines changed

.cspell.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"$schema": "https://raw.githubusercontent.com/streetsidesoftware/cspell/main/cspell.schema.json",
33
"version": "0.2",
4-
"ignorePaths": ["**/*.json", "**/*.css", "node_modules", "**/*.log", "**/*.http", "**/*.toml", "src/types/database.ts"],
4+
"ignorePaths": ["**/*.json", "**/*.css", "node_modules", "**/*.log", "**/*.http", "**/*.toml", "src/types/database.ts", "dist/**"],
55
"useGitignore": true,
66
"language": "en",
77
"words": ["Nektos", "dataurl", "devpool", "outdir", "servedir", "Supabase", "SUPABASE", "typebox", "ubiquibot", "Smee", "Rpcs", "hono"],

.gitattributes

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
dist/** linguist-generated
2+
bun.lockb linguist-generated

.github/knip.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import type { KnipConfig } from "knip";
22

33
const config: KnipConfig = {
4-
entry: ["build/index.ts"],
4+
entry: ["src/main.ts", "src/worker.ts"],
55
project: ["src/**/*.ts"],
66
ignore: ["**/__mocks__/**", "**/__fixtures__/**", "src/types/database.ts"],
77
ignoreExportsUsedInFile: true,

.github/workflows/compute.yml

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: "command-wallet"
1+
name: "Plugin Compute"
22

33
on:
44
workflow_dispatch:
@@ -15,17 +15,17 @@ on:
1515
description: "Auth Token"
1616
ref:
1717
description: "Ref"
18+
signature:
19+
description: "Signature tp identify the Kernel"
1820
command:
19-
required: true
21+
description: "Command"
2022

2123
jobs:
2224
compute:
2325
name: "command-wallet"
2426
runs-on: ubuntu-latest
2527
permissions: write-all
26-
env:
27-
SUPABASE_URL: ${{ secrets.SUPABASE_URL }}
28-
SUPABASE_KEY: ${{ secrets.SUPABASE_KEY }}
28+
environment: ${{ github.ref == 'refs/heads/main' && 'main' || 'development' }}
2929

3030
steps:
3131
- uses: actions/checkout@v4
@@ -35,12 +35,10 @@ jobs:
3535
with:
3636
node-version: "20.10.0"
3737

38-
- name: install dependencies
39-
run: yarn
40-
4138
- name: execute directive
42-
run: npx tsx ./src/main.ts
43-
id: command-wallet
39+
run: node dist/index.js
4440
env:
41+
PLUGIN_GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
42+
KERNEL_PUBLIC_KEY: ${{ secrets.KERNEL_PUBLIC_KEY }}
4543
SUPABASE_URL: ${{ secrets.SUPABASE_URL }}
4644
SUPABASE_KEY: ${{ secrets.SUPABASE_KEY }}

.github/workflows/cspell.yml

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

.github/workflows/database.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,10 +24,13 @@ jobs:
2424
with:
2525
node-version: "20.10.0"
2626

27+
- name: Setup Bun
28+
uses: oven-sh/setup-bun@v2
29+
2730
- name: Generate Supabase Types
2831
run: |
29-
yarn install
30-
yarn run "supabase:generate:remote"
32+
bun install --frozen-lockfile
33+
bun run "supabase:generate:remote"
3134
3235
- name: Commit and Push generated types
3336
run: |
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: Formatting Check
2+
3+
on:
4+
push:
5+
6+
jobs:
7+
format-check:
8+
name: Check for formatting errors
9+
runs-on: ubuntu-latest
10+
11+
steps:
12+
- name: Checkout code
13+
uses: actions/checkout@v4
14+
15+
- name: Setup Bun
16+
uses: oven-sh/setup-bun@v2
17+
18+
- name: Install toolchain
19+
run: bun install --frozen-lockfile
20+
21+
- name: Eslint
22+
run: bun run eslint --fix-dry-run
23+
24+
- name: Cspell
25+
run: bun run format:cspell
26+
27+
- name: Prettier
28+
run: bun run prettier --check .

.github/workflows/jest-testing.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,14 @@ jobs:
2121
with:
2222
fetch-depth: 0
2323

24+
- name: Setup Bun
25+
uses: oven-sh/setup-bun@v2
26+
27+
- name: Install toolchain
28+
run: bun install --frozen-lockfile
29+
2430
- name: Jest With Coverage
25-
run: yarn install --immutable --immutable-cache --check-cache && yarn test
31+
run: bun run test
2632

2733
- name: Add Jest Report to Summary
2834
if: always()

.github/workflows/knip.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,14 +16,17 @@ jobs:
1616
with:
1717
node-version: 20.10.0
1818

19+
- name: Setup Bun
20+
uses: oven-sh/setup-bun@v2
21+
1922
- name: Install toolchain
20-
run: yarn install
23+
run: bun install --frozen-lockfile
2124

2225
- name: Store PR number
2326
run: echo ${{ github.event.number }} > pr-number.txt
2427

2528
- name: Run Knip
26-
run: yarn knip || yarn knip --reporter json > knip-results.json
29+
run: bun run knip || bun run knip --reporter json > knip-results.json
2730

2831
- name: Upload knip result
2932
if: failure()

.husky/commit-msg

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
#!/usr/bin/env sh
22
. "$(dirname -- "$0")/_/husky.sh"
33

4-
yarn commitlint --edit "$1"
4+
bun commitlint --edit "$1"

.husky/pre-commit

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
#!/usr/bin/env sh
22
. "$(dirname -- "$0")/_/husky.sh"
33

4-
yarn lint-staged
4+
bun lint-staged

.prettierignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
dist/
2+
coverage/

CHANGELOG.md

Lines changed: 6 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -2,26 +2,22 @@
22

33
## [1.1.0](https://github.com/Meniole/command-wallet/compare/v1.0.0...v1.1.0) (2024-07-16)
44

5-
65
### Features
76

8-
* added test for wallet link ([e059e13](https://github.com/Meniole/command-wallet/commit/e059e1329da781194a4f7a928be17015d2b28962))
9-
* parsing arguments and executing run ([70fb75e](https://github.com/Meniole/command-wallet/commit/70fb75e6e970d6439f5d9ba64ee51caa5edaf269))
10-
7+
- added test for wallet link ([e059e13](https://github.com/Meniole/command-wallet/commit/e059e1329da781194a4f7a928be17015d2b28962))
8+
- parsing arguments and executing run ([70fb75e](https://github.com/Meniole/command-wallet/commit/70fb75e6e970d6439f5d9ba64ee51caa5edaf269))
119

1210
### Bug Fixes
1311

14-
* fixed crash when user does not exist ([433a6a7](https://github.com/Meniole/command-wallet/commit/433a6a7c3f19b2722df75e7b826bc6b8e0244a1e))
12+
- fixed crash when user does not exist ([433a6a7](https://github.com/Meniole/command-wallet/commit/433a6a7c3f19b2722df75e7b826bc6b8e0244a1e))
1513

1614
## 1.0.0 (2024-07-08)
1715

18-
1916
### Features
2017

21-
* added test for wallet link ([e059e13](https://github.com/ubiquibot/command-wallet/commit/e059e1329da781194a4f7a928be17015d2b28962))
22-
* parsing arguments and executing run ([70fb75e](https://github.com/ubiquibot/command-wallet/commit/70fb75e6e970d6439f5d9ba64ee51caa5edaf269))
23-
18+
- added test for wallet link ([e059e13](https://github.com/ubiquibot/command-wallet/commit/e059e1329da781194a4f7a928be17015d2b28962))
19+
- parsing arguments and executing run ([70fb75e](https://github.com/ubiquibot/command-wallet/commit/70fb75e6e970d6439f5d9ba64ee51caa5edaf269))
2420

2521
### Bug Fixes
2622

27-
* fixed crash when user does not exist ([433a6a7](https://github.com/ubiquibot/command-wallet/commit/433a6a7c3f19b2722df75e7b826bc6b8e0244a1e))
23+
- fixed crash when user does not exist ([433a6a7](https://github.com/ubiquibot/command-wallet/commit/433a6a7c3f19b2722df75e7b826bc6b8e0244a1e))

README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,13 +9,13 @@ Allows users to register their wallets to collect rewards.
99

1010
## Getting Started
1111

12-
1. Install the dependencies preferably using `yarn` or `bun`.
12+
1. Install the dependencies preferably using `bun`.
1313
2. Copy `.dev.vars.example` to `.dev.vars` and fill the variables
1414
3. Generate Supabase types by running
15-
```shell
16-
yarn prebuild
17-
```
18-
4. Run the project with `yarn wrangler`
15+
```shell
16+
bun prebuild
17+
```
18+
4. Run the project with `bun wrangler`
1919

2020
## Example configuration
2121

bun.lockb

405 KB
Binary file not shown.

0 commit comments

Comments
 (0)