CodeMirror PRIMARY Bridge par Nicolas Hainaux
Restores middle-click paste from CodeMirror editors (GitHub Gist, codemirror.netâŠ) on Linux/BSD by forwarding selections to the X11/Wayland PRIMARY buffer. Per-domain allowlist, off by default. Requires a companion native helper.
MĂ©tadonnĂ©es de lâextension
Ă propos de cette extension
On Linux/BSD, CodeMirror-based editors (GitHub Gist, codemirror.net, and others) don't propagate text selections to the X11/Wayland PRIMARY buffer. The result: middle-click paste from those editors silently does nothing. This extension restores that workflow.
How it works
A content script watches the selection inside CodeMirror editors on allowlisted sites. When the selection changes, it sends the text to a small Python "native messaging host" running outside the browser, which
writes it to PRIMARY via
Two-part install
Full instructions, including the source repository, are at https://gitlab.com/nicolas.hainaux/cm_primary.
Security model
Off everywhere by default. The extension only forwards selections on hostnames you explicitly add to the allowlist in the options page â no allowlist entry, no message to the helper, no write to PRIMARY.
This mirrors the conservative choice Firefox made after CVE-2023-6208, which was patched by dropping all JavaScript-driven PRIMARY updates. This extension reopens that path only on sites you've explicitly trusted.
Privacy
No telemetry, no analytics, no remote servers. Selections are only forwarded to your local PRIMARY buffer.
Supported platforms
Linux X11 (tested with
How it works
A content script watches the selection inside CodeMirror editors on allowlisted sites. When the selection changes, it sends the text to a small Python "native messaging host" running outside the browser, which
writes it to PRIMARY via
xsel, xclip, or wl-copy.Two-part install
- The extension itself (this page).
- A small Python helper, installed separately by running
install.shfrom the source tree. WebExtension APIs cannot reach clipboard tools directly â the helper is required and AMO cannot install it for you.
Full instructions, including the source repository, are at https://gitlab.com/nicolas.hainaux/cm_primary.
Security model
Off everywhere by default. The extension only forwards selections on hostnames you explicitly add to the allowlist in the options page â no allowlist entry, no message to the helper, no write to PRIMARY.
This mirrors the conservative choice Firefox made after CVE-2023-6208, which was patched by dropping all JavaScript-driven PRIMARY updates. This extension reopens that path only on sites you've explicitly trusted.
Privacy
No telemetry, no analytics, no remote servers. Selections are only forwarded to your local PRIMARY buffer.
Supported platforms
Linux X11 (tested with
xsel). BSD and Wayland support is implemented but untested â feedback welcome.NotĂ© 0 par 1 personne
Autorisations et données
Autorisations nécessaires :
- Communiquer avec dâautres programmes que Firefox
- Accéder à vos données pour tous les sites web
Autorisations facultatives :
- Accéder à vos données pour tous les sites web
Collecte de données :
- Le dĂ©veloppeur indique que cette extension nâa pas besoin de collecter de donnĂ©es.
Plus dâinformations
- Version
- 1.0.0
- Taille
- 18,5Â Ko
- DerniĂšre mise Ă jour
- il y a 11 jours (4 juin 2026)
- Catégories associées
- Licence
- Licence MIT
- Historique des versions
- Ajouter Ă la collection