65 Commits

Author SHA1 Message Date
Tommaso Casaburi
a0b8d85969 Remove unsupported providers and align .bso parity (#825)
* fix(addresses): remove unsupported address providers

* fix(settings): keep only Ethereum chain providers

* feat(addresses): present ENS aliases as .bso

* refactor(avatars): remove avatar functionality

* feat(parity): align terminology and settings upgrades

* fix(community routes): canonicalize .bso URLs
2026-07-18 17:27:13 +07:00
Tommaso Casaburi
3c691effb3 Replace directories with living default communities (#824)
* Replace directories with address-owned defaults

* Translate default community updates

* Document default community behavior

* Use comments in CID routes

* Polish default community review flow

* fix(starter-subscriptions): harden list updates

* refactor(home): derive subscription state during render

* fix(routing): harden comments link handling

* fix(electron): load tar namespace export

* fix(subscriptions): leave after provenance races

* fix(routing): autolink default TLD shorthand

* fix(starter-subscriptions): show accurate fallback warning

* fix(home): wait for default community list

* fix(onboarding): recover from storage access errors

* fix(subscriptions): surface persistence failures
2026-07-15 15:43:53 +07:00
Tommaso Casaburi
ded8d51371 fix(deps): resolve open Dependabot security alerts
Bump vulnerable transitive dependencies via Yarn resolutions and replace
the unpatched decompress package with tar and extract-zip for Kubo archive
extraction in the Electron build pipeline.
2026-07-14 13:33:41 +07:00
Tommaso Casaburi
13e1078fbf chore: catch up to 5chan — deps, pkc-js RPC, AI workflow, default directory subscriptions (#820)
* chore(deps): upgrade bitsocial-react-hooks to 0.1.26 and core deps

- @bitsocial/bitsocial-react-hooks 0.1.2 -> 0.1.26
- add @pkcprotocol/pkc-js 0.0.62 and @bitsocial/bso-resolver 0.0.8 (electron RPC)
- react/react-dom 19.1.2 -> 19.2.7, @types/react 19.2.16, @types/react-dom 19.2.3
- vite 8.0.5 -> 8.0.16 (dep + resolution)
- node-fetch 2 -> 3.3.2, drop @types/node-fetch (v3 ships its own types)
- @types/node 20.8.2 -> 20.19.37, fs-extra 11.2.0 -> 11.3.0
- add @electron/rebuild 3.7.2 + electron:rebuild-native script (better-sqlite3
  now ships via pkc-js)

* refactor(electron): port RPC from plebbit-js to pkc-js

- replace start-plebbit-rpc.js with start-pkc-rpc.js + start-pkc-rpc-core.js
  (5chan template, same 9138 port and auth-key handling)
- add pkc-rpc-options.js with BSO name resolvers via @bitsocial/bso-resolver
- add pkc-paths.js: data dir moves from EnvPaths('plebbit') / .plebbit to
  EnvPaths('pkc') / .pkc, with a one-time rename of the legacy plebbit data
  dir so existing users keep their communities and accounts
- main.js, start-ipfs.js, log.js now resolve data/log paths through pkc-paths
- preload.mjs exposes window.defaultPkcOptions (pkcRpcClientsOptions) and
  window.pkcRpcAuthKey via pkc-named IPC channels

* chore: rename local data dir references from .plebbit to .pkc

- electron:before:delete-data clears both .pkc and legacy .plebbit
- android icons temp dir renamed to /tmp/seedit-android-icons
- forge.config.js excludes both .pkc and .plebbit from packages
- knip.jsonc drops @plebbit/plebbit-js entries now that the electron RPC
  imports @pkcprotocol/pkc-js directly

* fix: align renderer with pkc-named account options from hooks 0.1.26

- window.defaultPlebbitOptions -> window.defaultPkcOptions (p2p. subdomain)
- account.plebbitOptions/plebbitRpcClientsOptions -> pkcOptions/
  pkcRpcClientsOptions in settings views and account import utils
- account.plebbit -> account.pkc when stripping the client instance from
  account export/editor JSON
- rpc settings data path now read from pkcRpcSettings.pkcOptions.dataPath
- account import keeps a shim that upgrades legacy plebbitOptions exports
- drop unused catch binding in start-pkc-rpc.js (oxlint)

* chore(ai): move Claude Code hooks to .claude/settings.json entry point

Adopt the reworked hook entry points: Claude Code hooks now live in
.claude/settings.json (settings-format with $CLAUDE_PROJECT_DIR paths),
the obsolete .claude/hooks.json is removed, and .cursor/hooks.json is
updated to the compact format. Hook scripts are unchanged.

* chore(ai): sync agent descriptors with 5chan rework, adapted for seedit

Port the reworked agent descriptors across .claude, .cursor, and .codex:
tools: frontmatter for read-only agents, browser-session guidance,
untrusted page-content rules, machine-path removal, and yarn doctor/knip
verification guidance.

seedit adaptations: correct the Android appId to seedit.android (the old
copies wrongly said fivechan.android), use a seedit-test-api35 AVD name,
rewrite test-apk around the direct catbox.moe FileUploaderPlugin (seedit
has no WebView upload automation or instrumentation test suite), replace
5chan board/catalog route examples with /s/<community-address> routes,
and point react-scan wiring at vite.config.js instead of the 5chan-only
src/lib/react-scan.ts.

* fix(agent hooks): port harness payload parsing and stop-gate fixes from 5chan

The shared hook implementations now parse both Cursor ({file_path}) and
Claude/Codex ({tool_input: {file_path}}) stdin shapes, normalize absolute
paths to repo-relative, emit hookSpecificOutput additionalContext on
PostToolUse so reminders reach the model, honor stop_hook_active to avoid
stop loops, skip verification on a clean tree, and exit 2 (blocking) on
verify failure. sync-git-branches keeps bitsocialnet/seedit and gains the
unmerged-PR output check.

* docs(ai): merge 5chan AGENTS.md and playbook improvements, adapted for seedit

AGENTS.md: document the harness-specific hook entry points (.claude/
settings.json, .cursor/hooks.json, .codex/hooks.json), add the
ai-workflow:check router row and command, browser-session confirmation
rules for playwright verification, the translate-skill router row, and
reworked AI Tooling Rules ordering. seedit keeps its own project
overview, changelog-based maintenance rules, and stays without
DESIGN.md/blotter/low-spec/android-usb content.

Playbooks: rewrite hooks-setup.md around the new entry points and
shared script behavior, add the committed skills/subagents index to
skills-and-tools.md, and note the canonical commit/issue-format skills
in commit-issue-format.md (without 5chan's required-scope rule, which
seedit does not use).

* chore(ai): add toolchain drift validator from 5chan

Add scripts/validate-ai-workflow.mjs and the ai-workflow:check script.
Fix the one drift it found: seedit's .claude and .cursor copies of the
profile-browsing skill disagreed on the dev-server probe URL and the
Portless note.

* chore(ai skills): port generic 5chan skill fixes and correct seedit misadaptations

Port generic improvements: stale main->master branch names in deslop and
you-might-not-need-an-effect, invalid rg --type tsx flag in
fix-merge-conflicts, the reworked verified/update-in-place readme skill,
the Chesterton's Fence rule in refactor-pass, the independent-subagent-
verification rule in review-and-merge-pr, harness-neutral wording in
inspect-elements/implement-plan/translate.

Correct seedit misadaptations left over from the original copy: test-apk
now uses appId seedit.android, a seedit AVD, and the direct catbox.moe
FileUploaderPlugin flow instead of 5chan's WebView upload automation and
instrumentation suite; profile-browsing drops 5chan board-code routes for
/s/<community-address>.

Kept seedit-flavored: commit-format (no required scope), release and
release-description (no blotter), doctor-vs-repo-standard verification
wording in implement-plan and review-and-merge-pr.

* docs(llms): regenerate llms indexes after AGENTS.md and playbook updates

* feat(directories): add directory list utils, vendored data and sync script

Port 5chan's directory machinery adapted to seedit terminology: per-code
candidate community lists, ranking/winner selection, directory codes as
subscription entries, legacy default migration transform, and a vendored
mirror of bitsocialnet/lists/seedit-directories with a sync:directories
script.

* feat(directories): resolve subscriptions and defaults from directory lists

Add hooks that fetch per-code candidate lists from the lists repo (1h
localStorage cache, in-flight dedup, vendored fallback), pick the
highest-ranked online winner with offline rotation, expand
account.subscriptions directory codes at read time, and derive the
default communities for /s/all from the union of all directory winners.
Rework the one-time auto-subscribe into the directory migration: drop
the dead legacy default communities and subscribe the 10 directory
codes under a new per-account localStorage guard.

* feat(directories): directory routes, feeds and subscribe UI

/s/<code> resolves like a community page via the directory winner while
/s/<address> keeps working; the home feed expands directory-code
subscriptions into winner addresses without flashing the empty state;
the subscribe button targets the code on directory routes with a
'subscribe to this community only' pin action; subscription lists render
directory entries as s/<code> with a (directory) marker and the resolved
community as subtitle.

* test(directories): cover directory codes, winner ranking and migration

Vitest coverage for isDirectoryCode (reserved words, dots, unknown
codes), candidate ranking and offline rotation, subscription expansion
dedupe, list normalization with defaults, and the legacy migration
transform including idempotence.

* style(directories): apply oxfmt formatting

* chore(directories): vendor real community addresses for the 10 default directories

* chore(profiling): port 5chan dev-only react-scan setup for report API and __PROFILING__ flag

Replace the @react-scan/vite-plugin-react-scan wiring with 5chan's manual
dev-only src/lib/react-scan.ts, imported in the entry file. It exposes
window.__getReactScanReport() and window.__ELEMENT_SOURCE__ (element-source
helpers the inspect-elements skill already referenced) and honors
window.__PROFILING__ to hide the toolbar during automated profiling.
Update profile-browsing SKILL.md and profiler agent copies to match.

* chore(directories): vendor .bso names for default directory communities

* fix(subscriptions): retry directory migration in-session after transient setAccount failure

* fix(electron): migrate legacy project-root .plebbit dev data dir to .pkc

* fix(directories): seed useDirectoryLists synchronously from cache/vendored data

* test(directories): guard directory codes against defaults drift

* chore(scripts): reject path-traversal file names in sync-directories

* fix(profiling): handle react-scan chunk-load failure and dedupe not-ready stubs

* style(directories): replace deprecated word-wrap with overflow-wrap

* docs(agents): align test-apk logcat reference, broaden conflict-marker scan, dedupe committed skills guidance

* chore(directories): vendor pics-posting.bso name

* fix(review): address PR feedback

* fix(review): address migration race feedback
2026-07-04 21:34:18 +07:00
plebeius
e294bc3c8b fix(electron-forge): add app icon configuration for all platforms 2026-01-30 13:46:23 +08:00
plebeius
e1575de5fc fix(electron): fix production build crashes 2026-01-30 13:11:44 +08:00
plebeius
61c470141b refactor(electron): migrate build-docker.sh to Electron Forge and add arch-specific scripts
Updated build-docker.sh to use Electron Forge instead of electron-builder, switched from electronuserland/builder image to node:22, and removed electron-builder-specific commands. Added architecture-specific build scripts (linux:x64, linux:arm64, mac:x64, mac:arm64) to package.json for CI workflow. Removed outdated electron-rebuild comment from release.yml.
2026-01-30 12:16:09 +08:00
plebeius
2ad78b9acd fix CI 2026-01-29 18:57:28 +08:00
plebeius
07a7dad061 fix(electron): use pathToFileURL for kubo dynamic import 2026-01-29 14:49:49 +08:00
plebeius
d65e2d43b7 refactor: migrate from electron-builder to Electron Forge and use kubo npm package
Migrated build system from electron-builder to Electron Forge with new configuration in forge.config.js. Replaced manual IPFS binary downloads with kubo npm package, updating start-ipfs.js to resolve binaries from node_modules. Simplified CI workflows to use new build scripts and verification helpers. Added scripts to find and verify executables in Forge output directory.
2026-01-29 14:39:27 +08:00
plebeius
9cdb57ebca fix lint warnings 2026-01-15 19:09:03 +01:00
plebeius
a33d708e06 fix(electron): keep module-scoped Tray ref and destroy before reassign 2025-09-26 22:08:52 +02:00
plebeius
e5e6aa4bf7 perf(linux): avoid GTK mixups by sanitizing env and skipping tray on Wayland
We hardened Linux startup to prevent mixed GTK crashes some GNOME users hit. We now default Electron to X11 and sanitize common GTK injectors, and disable the tray by default on Wayland with an opt-in flag. Should make AppImage start reliably without user tweaks.
2025-09-26 22:03:01 +02:00
plebeius
6c1c3ecd07 ci(release): fix mac arm failure, add arch matrices, arch-aware IPFS, and OS-grouped release notes
Replace ensurepip with setup-python on macOS-14; build and publish arm64/x64 variants for mac/linux/windows; select IPFS binaries by target arch (with SEEDIT_BUILD_ARCH override); generate cleaner OS-grouped release notes from actual dist artifacts.
2025-08-18 13:23:23 +02:00
plebeius
c9f3ba8822 perf(electron): reduce prod logging + IPFS noise across OS; disable devtools in release; arch-aware mac builds
Reduce production logging and I/O by avoiding main-process console.log/debug file writes, setting GOLOG_LOG_LEVEL=error and stopping IPFS daemon stdout piping in production, and disabling devtools in packaged builds; additionally build mac artifacts per arch and fetch matching IPFS binaries to avoid emulation overhead. These changes address lag in release builds across OS caused by log-induced stalls and architecture mismatch.
2025-08-17 18:42:37 +02:00
plebeius
63bb2adc82 fix(electron): add missing file uploader IPC channels 2025-06-13 18:20:23 +02:00
Tom (plebeius.eth)
5dddd9ee46 fix(electron): "share" button couldn't copy link to clipboard 2025-05-30 23:04:48 +02:00
Tom (plebeius.eth)
d02d548026 unnecessary value 2025-05-23 12:43:17 +02:00
Tom (plebeius.eth)
0767774c86 Update before-pack.js 2025-05-21 14:53:50 +02:00
Tom (plebeius.eth)
9a3481cbdb fix(electron): resolve preload script module errors and ensure proper bundling 2025-05-19 18:28:04 +02:00
Tom (plebeius.eth)
0da1d88acd fix electron, fix capacitor 2025-05-13 22:59:09 +02:00
Tom (plebeius.eth)
ff3874cb46 Update before-pack.js 2025-05-11 14:56:03 +02:00
Tom (plebeius.eth)
4ac3c02dff fix(electron): add CJS wrapper for after-all-artifact-build hook 2025-05-11 00:06:18 +02:00
Tom (plebeius.eth)
6d56f2a84f Update before-pack.js 2025-05-10 23:49:25 +02:00
Tom (plebeius.eth)
1c16cc0551 fix context flags, ipc methods, push notification logic 2025-05-04 23:04:44 +02:00
Tom (plebeius.eth)
9013d6b5db fix path 2025-05-03 22:55:12 +02:00
Tom (plebeius.eth)
f08a10a2b3 feat: add push notifications to web browser, android app, desktop app 2025-05-02 22:29:11 +02:00
Tom (plebeius.eth)
6682219da0 fix electron 2025-04-29 15:43:13 +02:00
Tom (plebeius.eth)
ee37b49d88 feat(embeds): add PDF support for direct links and pdf file upload 2025-04-05 16:51:33 +02:00
Tom (plebeius.eth)
55f32bddbb update script, logs 2025-04-01 14:43:15 +02:00
Tom (plebeius.eth)
840e36255b fix env paths 2025-04-01 13:29:27 +02:00
Tom (plebeius.eth)
6444fb5b06 fix(electron): migrate Electron files to CommonJS for cross-platform compatibility
fixes conflicts between ES Modules used by Vite and CommonJS modules needed by Electron in packaged applications
2025-04-01 00:29:25 +02:00
Tom (plebeius.eth)
d85ee22818 fix electron errors 2025-03-31 18:52:30 +02:00
Tom (plebeius.eth)
0c1475524f revert 2025-03-31 16:42:32 +02:00
Tom (plebeius.eth)
a424575f20 fix electron 2025-03-30 18:12:27 +02:00
Tom (plebeius.eth)
82022fa13c fix: fix electron 2025-03-30 17:15:48 +02:00
Tom (plebeius.eth)
ec989f5e9c fix(electron): bundle main process to resolve ESM issues in Linux AppImage 2025-03-30 16:02:53 +02:00
Tom (plebeius.eth)
7e7a039f1e fix(electron): bundle main process to resolve ESM issues in Linux AppImage 2025-03-30 15:58:15 +02:00
Tom (plebeius.eth)
8f7d8e32c6 fix(electron): replace electron-is-dev with app.isPackaged
This resolves a runtime error in the packaged Linux AppImage where electron-is-dev could not be found.
2025-03-29 23:58:47 +01:00
Tom (plebeius.eth)
dc43aeb993 feat(submit page): add media file upload
On desktop or android, the user can drop or select a media file in the upload box, which automatically uploads it to catbox.moe in the background, and pastes the direct link to the media in the url field.
2025-03-19 21:40:24 +01:00
Tom (plebeius.eth)
c65faa4936 upgrade electron
improves desktop app performance
2025-03-12 14:48:33 +01:00
Tom (plebeius.eth)
88a1ead60b migrate from CRA to Vite, upgrade to React 19 2025-03-08 22:35:26 +01:00
Esteban Abaroa
b191689fe1 chore(electron): update router urls 2025-01-04 00:19:24 +00:00
Esteban Abaroa
eaf9704250 refactor(electron): typo 2024-12-07 22:56:25 +00:00
Esteban Abaroa
97221d665d fix(electron): auto restart script more reliable 2024-12-07 22:50:55 +00:00
Esteban Abaroa
c66d454373 fix(electron): ipfs proxy should have error status code 2024-12-07 21:16:01 +00:00
Esteban Abaroa
6eced8c9f3 refactor(electron): change IPFS API port to 50019 2024-12-07 17:33:23 +00:00
Esteban Abaroa
69726e1b97 feat(electron): add http routers to electron 2024-11-19 18:39:47 +00:00
Tom (plebeius.eth)
faa33f08bf fix(electron): "ipfs warning" without error message would appear after closing the desktop app 2024-10-11 11:14:40 +02:00
Tom (plebeius.eth)
3a39eda7e6 fix(electron): isElectron flag was missing 2024-10-11 11:14:14 +02:00