No description
  • TypeScript 90.6%
  • HTML 6.4%
  • Dockerfile 3%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
2026-07-06 19:25:04 +02:00
extension Initial sourcedump app 2026-07-06 19:00:52 +02:00
scripts Add extension zip build script 2026-07-06 19:12:39 +02:00
src Group plain text output by date 2026-07-06 19:25:04 +02:00
test Group plain text output by date 2026-07-06 19:25:04 +02:00
.dockerignore Initial sourcedump app 2026-07-06 19:00:52 +02:00
.gitignore Initial sourcedump app 2026-07-06 19:00:52 +02:00
bun.lock Initial sourcedump app 2026-07-06 19:00:52 +02:00
docker-compose.yml Initial sourcedump app 2026-07-06 19:00:52 +02:00
Dockerfile Initial sourcedump app 2026-07-06 19:00:52 +02:00
index.ts Initial sourcedump app 2026-07-06 19:00:52 +02:00
package.json Add extension zip build script 2026-07-06 19:12:39 +02:00
README.md Add extension zip build script 2026-07-06 19:12:39 +02:00
tsconfig.json Initial sourcedump app 2026-07-06 19:00:52 +02:00

sourcedump

A small Bun/TypeScript app that saves the URLs of all currently open Chrome tabs.

It has two parts:

  • a Bun web service with SQLite storage
  • a Chrome extension that dumps tabs when its shortcut is pressed

Service

Install dependencies:

bun install

Run the service:

SOURCEDUMP_TOKEN=change-me bun run dev

On PowerShell:

$env:SOURCEDUMP_TOKEN = "change-me"
bun run dev

Configuration:

  • SOURCEDUMP_TOKEN is required.
  • SOURCEDUMP_DB defaults to sourcedump.sqlite.
  • PORT defaults to 3000.

Endpoints:

  • POST /api/dump accepts { "tabs": [{ "url": "...", "title": "...", "windowId": 1 }] }.
  • GET / returns all saved URLs as text/plain, one URL per line.
  • GET /health returns a simple health response.

Authenticated requests use Authorization: Bearer <token>. For opening the plain list in a browser, GET /?token=<token> is also accepted.

Chrome extension

Build the extension:

bun run build:extension

Build a distributable ZIP:

bun run build:extension:zip

The ZIP is written to out/sourcedump-extension.zip. Unzip it and load the extracted directory with Chrome's Load unpacked flow.

Load it in Chrome:

  1. Open chrome://extensions.
  2. Enable Developer mode.
  3. Choose Load unpacked.
  4. Select the extension directory.
  5. Open the extension options page and set the service URL and token.

The default shortcut is Ctrl+Shift+Y. Chrome does not allow F24 as a default extension command key, but shortcuts can be reviewed or changed at chrome://extensions/shortcuts.

Development

bun run typecheck
bun test
bun run build:extension
bun run build:extension:zip