Skip to content

Commit 4082e4d

Browse files
authored
Use submodules to maintain a long-term fork of Overtype (#31 fixes #3, #27)
2 parents 9a0e101 + cf2e9e2 commit 4082e4d

28 files changed

+6094
-12652
lines changed

.github/workflows/browser-extension.yml

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -11,16 +11,19 @@ jobs:
1111
runs-on: ubuntu-latest
1212
steps:
1313
- uses: actions/checkout@v5
14+
with:
15+
submodules: recursive
16+
- uses: pnpm/action-setup@v4
17+
with:
18+
version: 10
1419
- uses: actions/setup-node@v5
1520
with:
1621
node-version-file: '.nvmrc'
17-
cache: 'npm'
18-
cache-dependency-path: browser-extension/package-lock.json
19-
- run: npm ci
20-
working-directory: browser-extension
21-
- run: npm run biome
22+
cache: 'pnpm'
23+
- run: pnpm install --frozen-lockfile
24+
- run: pnpm run biome
2225
working-directory: browser-extension
23-
- run: npm test
26+
- run: pnpm test
2427
working-directory: browser-extension
25-
- run: npm run compile
28+
- run: pnpm run typecheck
2629
working-directory: browser-extension

.gitmodules

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
[submodule "packages/overtype"]
2+
path = packages/overtype
3+
url = https://github.com/diffplug/overtype.git

browser-extension/README.md

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@
44

55
### Hotreload development
66

7-
- `npm install`
8-
- `npm run dev`
7+
- `pnpm install`
8+
- `pnpm run dev`
99
- open [`chrome://extensions`](chrome://extensions)
1010
- toggle **Developer mode** (top-right)
1111
- click "Load unpacked" (far left)
@@ -14,15 +14,15 @@
1414
- click the puzzle icon next to the url bar, then pin the Gitcasso icon
1515

1616
### Testing and quality
17-
- `npm run biome` - runs `biome check` (lint & formatting)
18-
- `npm run biome:fix` - fixes most of what `biome check` finds
19-
- `npm run compile` - typechecking
20-
- `npm test` - vitest
21-
- `npm test -- -u` updates all the snapshots
17+
- `pnpm run biome` - runs `biome check` (lint & formatting)
18+
- `pnpm run biome:fix` - fixes most of what `biome check` finds
19+
- `pnpm run compile` - typechecking
20+
- `pnpm test` - vitest
21+
- `pnpm test -- -u` updates all the snapshots
2222

2323
### Deployment
24-
- `npm run build` - build for mv3 for most browsers
25-
- `npm run build:firefox` - build mv2 specifically for Firefox
24+
- `pnpm run build` - build for mv3 for most browsers
25+
- `pnpm run build:firefox` - build mv2 specifically for Firefox
2626

2727
## How it works
2828

@@ -48,15 +48,15 @@ When the `textarea` gets removed from the page, the `TextareaRegistry` is notifi
4848

4949
In `tests/har` there are various `.har` files. These are complete recordings of a single page load.
5050

51-
- `npm run har:view` and you can see the recordings, with or without our browser extension.
51+
- `pnpm run har:view` and you can see the recordings, with or without our browser extension.
5252

5353
### Recording new HAR files
5454

5555
- you can add or change URLs in `tests/har-index.ts`
5656
- `npx playwright codegen https://github.com/login --save-storage=playwright/.auth/gh.json` will store new auth tokens
5757
- login manually, then close the browser
5858
- ***these cookies are very sensitive! we only run this script using a test account that has no permissions or memberships to anything, recommend you do the same!***
59-
- `npm run har:record` this records new snapshots using those auth tokens (it needs args, run it with no args for docs)
59+
- `pnpm run har:record` this records new snapshots using those auth tokens (it needs args, run it with no args for docs)
6060
- DO NOT COMMIT AND PUSH NEW OR CHANGED `har` files!
6161
- we try to sanitize these (see `har-record.ts` for details) but there may be important PII in them
6262
- if you need new HAR files for something, let us know and we will generate them ourselves using a dummy account

browser-extension/biome.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"$schema": "https://biomejs.dev/schemas/2.2.2/schema.json",
2+
"$schema": "https://biomejs.dev/schemas/2.2.3/schema.json",
33
"assist": {
44
"actions": {
55
"source": {

0 commit comments

Comments
 (0)