{"id":13902956,"url":"https://github.com/egovelox/mozeidon","last_synced_at":"2025-09-07T18:03:58.758Z","repository":{"id":224426208,"uuid":"763220413","full_name":"egovelox/mozeidon","owner":"egovelox","description":"Mozeidon is a CLI to handle Firefox or Chrome tabs, history and bookmarks.","archived":false,"fork":false,"pushed_at":"2025-07-14T11:06:22.000Z","size":37664,"stargazers_count":41,"open_issues_count":5,"forks_count":1,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-07-14T14:49:06.763Z","etag":null,"topics":["addons-mozilla-org","bookmarks","browser-bookmarks","browser-history","browser-tabs","chrome","chrome-extensions","cli","go","mozilla","raycast","tabs"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/egovelox.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2024-02-25T21:19:13.000Z","updated_at":"2025-07-10T19:27:56.000Z","dependencies_parsed_at":"2024-03-29T10:27:35.779Z","dependency_job_id":"91507f9a-407d-4fc5-8fff-94073e0fa30a","html_url":"https://github.com/egovelox/mozeidon","commit_stats":null,"previous_names":["egovelox/mozeidon"],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/egovelox/mozeidon","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/egovelox%2Fmozeidon","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/egovelox%2Fmozeidon/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/egovelox%2Fmozeidon/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/egovelox%2Fmozeidon/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/egovelox","download_url":"https://codeload.github.com/egovelox/mozeidon/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/egovelox%2Fmozeidon/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":265685524,"owners_count":23811191,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["addons-mozilla-org","bookmarks","browser-bookmarks","browser-history","browser-tabs","chrome","chrome-extensions","cli","go","mozilla","raycast","tabs"],"created_at":"2024-08-06T22:01:31.235Z","updated_at":"2025-07-18T00:33:00.401Z","avatar_url":"https://github.com/egovelox.png","language":"TypeScript","funding_links":[],"categories":["TypeScript","cli"],"sub_categories":[],"readme":"# 🔱 Mozeidon \n\nTLDR;\n- Handle your tabs, bookmarks and history from outside of your web-browser.\n- [🆕 Installation of the mozeidon brew cask](https://github.com/egovelox/mozeidon-macos-ui?tab=readme-ov-file#homebrew)\n\n## Intro\nMozeidon is essentially a CLI written in [Go](https://go.dev/) to handle [Mozilla Firefox](https://www.mozilla.org/firefox/) OR [Google Chrome](https://www.google.com/chrome) tabs, history, and bookmarks. \n\nHere you'll find :\n- a guide to complete the [installation](https://github.com/egovelox/mozeidon/tree/main?tab=readme-ov-file#installation) of the mozeidon components (see [architecture](https://github.com/egovelox/mozeidon/tree/main?tab=readme-ov-file#architecture)).\n- [advanced examples](https://github.com/egovelox/mozeidon/tree/main?tab=readme-ov-file#examples) of the CLI usage (including integration with `fzf` and `fzf-tmux`) \n- [a Raycast extension](https://github.com/egovelox/mozeidon/tree/main?tab=readme-ov-file#raycast-extension) built around Mozeidon CLI (for MacOS only)\n- [a MacOS native app](https://github.com/egovelox/mozeidon/tree/main?tab=readme-ov-file#macos-swift-app-agent) built around Mozeidon CLI (for MacOS only)\n\nAll the code is available here as open-source. You can be sure that :\n- your browsing data (tabs, bookmarks, etc) will remain private and safe: mozeidon will never share anything outside of your system.\n- at any time, stopping or removing the mozeidon firefox (or chrome) addon extension will stop or remove all related processes on your machine.\n\nUsing the ``mozeidon`` CLI, you can : \n- list all currently opened tabs\n- list recently-closed tabs\n- list current history\n- list current bookmarks\n- switch to a currently opened tab\n- open a new tab (empty tab or with target url)\n- close a currently opened tab\n\n\u003cimg width=\"1512\" alt=\"mozeidon-cli\" src=\"https://github.com/egovelox/mozeidon/assets/56078155/2cfd04c2-d066-49fa-973e-c389e90b1f37\"\u003e\n\u003cbr/\u003e\u003cbr/\u003e\n\n\u003cimg width=\"1512\" alt=\"mozeidon-cli-2\" src=\"https://github.com/egovelox/mozeidon/assets/56078155/9ba5c99b-0436-433c-9b73-427f2b3c897f\"\u003e\n\u003cbr/\u003e\u003cbr/\u003e\n\n\n## Architecture\n\n\n\u003cimg width=\"788\" alt=\"mozeidon-architecture\" src=\"https://github.com/egovelox/mozeidon/assets/56078155/15192276-e85f-4de0-956d-6eba0517303b\"\u003e\n\u003cbr/\u003e\u003cbr/\u003e\n\nMozeidon is built on ipc and native-messaging protocols, using the following components :\n\n- the [Mozeidon firefox or chrome add-on](https://github.com/egovelox/mozeidon/tree/main?tab=readme-ov-file#mozeidon-firefox-addon), a JS script running in the Mozilla (or Chrome) browser, receives commands and sends back data (i.e tabs, bookmarks, etc) by leveraging various browser APIs.\n\n- the [Mozeidon native-app](https://github.com/egovelox/mozeidon/tree/main?tab=readme-ov-file#mozeidon-native-app), a Go program, interacts with the Mozeidon firefox-addon. It sends commands to, and receive data from the browser addon - via [native-messaging](https://developer.mozilla.org/docs/Mozilla/Add-ons/WebExtensions/Native_messaging) protocol.\n\n- the [Mozeidon CLI](https://github.com/egovelox/mozeidon/tree/main?tab=readme-ov-file#mozeidon-cli), another Go program, interacts with the Mozeidon native-app. It sends commands to and receive data from the native-app - via ipc protocol.\n\n\n## Installation \n\nYou need to install at least 3 components :\n- the [Mozeidon firefox add-on](https://github.com/egovelox/mozeidon/tree/main?tab=readme-ov-file#mozeidon-firefox-addon) or the [Mozeidon chrome add-on](https://github.com/egovelox/mozeidon/tree/main?tab=readme-ov-file#mozeidon-chrome-addon)\n- the [Mozeidon native-app](https://github.com/egovelox/mozeidon/tree/main?tab=readme-ov-file#mozeidon-native-app)\n- the [Mozeidon CLI](https://github.com/egovelox/mozeidon/tree/main?tab=readme-ov-file#mozeidon-cli)\n\n## Mozeidon firefox-addon\n\nThe mozeidon addon for Mozilla Firefox can be found here :\n\n[https://addons.mozilla.org/en-US/firefox/addon/mozeidon](https://addons.mozilla.org/en-US/firefox/addon/mozeidon)\n\n## Mozeidon chrome-addon\n\nThe mozeidon addon for Google Chrome can be found here :\n\n[https://chromewebstore.google.com/detail/mozeidon/lipjcjopdojfmfjmnponpjkkccbjoipe](https://chromewebstore.google.com/detail/mozeidon/lipjcjopdojfmfjmnponpjkkccbjoipe)\n\n## Mozeidon native-app\n\nThe [mozeidon native-app](https://github.com/egovelox/mozeidon-native-app), a very simple ipc server written in ``go``, will allow the mozeidon add-on to receive commands from and send responses to the mozeidon CLI ([see below](https://github.com/egovelox/mozeidon/tree/main?tab=readme-ov-file#mozeidon-cli)).\n\nOn MacOS or Linux, you can install it using ``homebrew`` :\n```bash\nbrew tap egovelox/homebrew-mozeidon ;\n\nbrew install egovelox/mozeidon/mozeidon-native-app ;\n```\n\nOtherwise, you may download the binary from the [release page](https://github.com/egovelox/mozeidon-native-app/releases).\n\nIf no release matches your platform, you can build the binary yourself:\n```bash\ngit clone https://github.com/egovelox/mozeidon-native-app.git ;\n\ncd mozeidon-native-app \u0026\u0026 go build\n```\n\u003cbr/\u003e\nAs a firefox native-app, it has to be referenced into your Firefox or Chrome configuration.\n\n### Referencing the native-app into your Firefox configuration\n\nOn ``MacOS``, first locate the ``~/Library/Application Support/Mozilla/NativeMessagingHosts`` directory (or create it if missing).\n\nThen create a ``mozeidon.json`` file, and copy into it the following ``json``.\n\nNote: depending on your installation, you may need to replace the value in ``\"path\"`` with the absolute path of the mozeidon-native-app.\n\n```json\n{\n  \"name\": \"mozeidon\",\n  \"description\": \"Native messaging add-on to interact with your browser\",\n  \"path\": \"/opt/homebrew/bin/mozeidon-native-app\",\n  \"type\": \"stdio\",\n  \"allowed_extensions\": [\n    \"mozeidon-addon@egovelox.com\"\n  ]\n}\n```\n\nNow the Mozeidon firefox-addon will be able to interact with the Mozeidon native-app.\n\nNote : \nFor other OS than ``MacOS``, please check the [Mozilla documentation](https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/Native_manifests#manifest_location) to find the correct location of the Firefox ``NativeMessagingHosts`` directory.\n\nAs a last step, you need to install the [Mozeidon CLI](https://github.com/egovelox/mozeidon/tree/main?tab=readme-ov-file#mozeidon-cli).\n\n### Referencing the native-app into your Chrome configuration\n\nOn ``MacOS``, first locate the ``~/Library/Application Support/Google/Chrome/NativeMessagingHosts`` directory (or create it if missing).\n\nThen create a ``mozeidon.json`` file, and copy into it the following ``json``.\n\nNote: depending on your installation, you may need to replace the value in ``\"path\"`` with the absolute path of the mozeidon-native-app.\n\n```json\n{\n  \"name\": \"mozeidon\",\n  \"description\": \"Native messaging add-on to interact with your browser\",\n  \"path\": \"/opt/homebrew/bin/mozeidon-native-app\",\n  \"type\": \"stdio\",\n  \"allowed_origins\": [\"chrome-extension://lipjcjopdojfmfjmnponpjkkccbjoipe/\"]\n}\n```\n\nNow the Mozeidon chrome-addon will be able to interact with the Mozeidon native-app.\n\nNote : \nFor other OS than ``MacOS``, please check the [Chrome documentation](https://developer.chrome.com/docs/extensions/develop/concepts/native-messaging#native-messaging-host-location) to find the correct location of the Chrome ``NativeMessagingHosts`` directory.\n\nAs a last step, you need to install the [Mozeidon CLI](https://github.com/egovelox/mozeidon/tree/main?tab=readme-ov-file#mozeidon-cli).\n\n## Mozeidon CLI\n\nThe Mozeidon CLI is a lightweight CLI written in ``go``. \n\nOn MacOS or Linux, you can install it using ``homebrew`` :\n```bash\nbrew tap egovelox/homebrew-mozeidon ;\n\nbrew install egovelox/mozeidon/mozeidon ;\n```\n\nOtherwise, you may download the binary from the [release page](https://github.com/egovelox/mozeidon/releases).\n\nIf no release matches your platform, you can build the binary yourself:\n```bash\ngit clone https://github.com/egovelox/mozeidon.git ;\n\ncd mozeidon/cli \u0026\u0026 go build\n```\n\n## Examples \n\n### How to use the Mozeidon CLI with ``go-template`` syntax for customized output :\n\n```bash\n# get maximum 10 of latest bookmarks, title and url\n\nmozeidon bookmarks -m 10 --go-template '{{range .Items}}{{.Title}} {{.Url}}{{\"\\n\"}}{{end}}'\n```\n\n```bash\n# get opened tabs, with 📌 icon if pinned\n\nmozeidon tabs get --go-template '{{range .Items}}{{.WindowId}}:{{.Id}} {{.Url}} {{if .Pinned}}📌{{else}}🦊{{end}} {{\"\\\\u001b[38;5;109m\"}} {{.Domain}}{{\"\\\\033[0m\"}} {{.Title}}{{\"\\n\"}}{{end}}'\n```\n\n### Customized tabs output with a pipe into ``fzf``\n\nIf you've installed [fzf](https://github.com/junegunn/fzf) you can use it as a kind of UI for mozeidon CLI.\n\nThe below `bash` command shows how `fzf` can be used to select a tab, and to open it in your browser.\n\n```bash\nmozeidon tabs get --go-template '{{range .Items}}{{.WindowId}}:{{.Id}} {{.Url}} {{if .Pinned}}📌{{else}}🦊{{end}} {{\"\\u001b[38;5;109m\"}} {{.Domain}}{{\"\\033[0m\"}} {{.Title}}{{\"\\n\"}}{{end}}' \\\n| fzf --ansi --with-nth 3.. --bind=enter:accept-non-empty \\\n| cut -d ' ' -f1 \\\n| xargs -n1 -I % sh -c 'mozeidon tabs switch % \u0026\u0026 open -a firefox'\n```\n\nnote : ``xargs -n1`` prevents to run any command if no tab was chosen with fzf ( say, for example, that you exited fzf with ctrl-c )\n\nnote : ``mozeidon tabs switch`` is used to switch to the tab you chose in fzf\n\n### Same as previous, but tailored for tmux\n\nAs an example, let's bind our mozeidon script with the tmux shortcut ``Prefix-t``\n\n```bash\n# in $HOME/.tmux.conf\nbind t run-shell -b \"bash $HOME/.tmux/mozeidon_tabs.sh\"\n```\n\nNow create the script ``$HOME/.tmux/mozeidon_tabs.sh`` :\n\n```bash\n#!/bin/bash\nmozeidon tabs get --go-template \\\n'{{range .Items}}{{.WindowId}}:{{.Id}} {{.Url}} {{if .Pinned}}📌{{else}}🦊{{end}} {{\"\\u001b[38;5;109m\"}} {{.Domain}}{{\"\\033[0m\"}}  {{.Title}}{{\"\\n\"}}{{end}}' \\\n| fzf-tmux -p 60% -- \\\n--no-bold --layout=reverse --margin 0% --no-separator --no-info --black --color bg+:black,hl:reverse,hl+:reverse,gutter:black --ansi --with-nth 3.. --bind=enter:accept-non-empty \\\n| cut -d ' ' -f1 \\\n| xargs -n1 -I % sh -c '$HOME/bin/mozeidon tabs switch % \u0026\u0026 open -a firefox'\n```\n\n### Another advanced fzf-tmux script\n\nThis more advanced script will allow to :\n- open a new tab (empty or with search query)\n- switch to a currently open tab\n- close one or many tabs\n\n```bash\n#!/bin/bash\n$HOME/bin/mozeidon tabs get --go-template \\\n  '{{range .Items}}{{.WindowId}}:{{.Id}} {{.Url}} {{if .Pinned}}📌{{else}}🦊{{end}} {{\"\\u001b[38;5;109m\"}}  {{.Domain}}{{\"\\033[0m\"}}  {{.Title}}{{\"\\n\"}}{{end}}'\\\n  | fzf-tmux -p 60% -- \\\n  --border-label=TABS \\\n  --no-bold \\\n  --layout=reverse \\\n  --margin 0% \\\n  --no-separator \\\n  --no-info \\\n  --black \\\n  --color bg+:black,hl:reverse,hl+:reverse,gutter:black \\\n  --with-nth 3.. \\\n  --bind=\"enter:accept+execute($HOME/bin/mozeidon tabs switch {1} \u0026\u0026 open -a firefox)\" \\\n  --multi \\\n  --marker=❌ \\\n  --bind=\"ctrl-p:accept-non-empty+execute($HOME/bin/mozeidon tabs close {+1})\" \\\n  --bind=\"ctrl-o:print-query\" \\\n  --header-first \\\n  --color=header:#5e6b6b \\\n  '--header=close tab(s) [C-p] \nopen new tab [C-o]'\\\n  | grep -v \"[🦊📌]\" \\\n  | xargs -r -I {} sh -c '$HOME/bin/mozeidon tabs new \"{}\" \u0026\u0026 open -a firefox'\n```\n\n## Raycast extension\n\nFor MacOS and Firefox users only : see [the Mozeidon Raycast extension](https://www.raycast.com/egovelox/mozeidon).\n\nThis Raycast extension will not work with Chrome browser. If you use MacOS, see [MacOS swift app-agent](https://github.com/egovelox/mozeidon/tree/main?tab=readme-ov-file#macos-swift-app-agent)\n\nNote that you'll first need to complete the installation of Mozeidon components ([Mozeidon firefox add-on](https://github.com/egovelox/mozeidon/tree/main?tab=readme-ov-file#mozeidon-firefox-addon), [Mozeidon native-app](https://github.com/egovelox/mozeidon/tree/main?tab=readme-ov-file#mozeidon-native-app) and [Mozeidon CLI](https://github.com/egovelox/mozeidon/tree/main?tab=readme-ov-file#mozeidon-cli)).\n\nNote that you cannot list **history items** with this Raycast extension : only **tabs**, **recently-closed tabs**, and **bookmarks**.\n\n![mozeidon-4](https://github.com/egovelox/mozeidon/assets/56078155/a3b8d378-7fe2-4062-9722-15b4cf7f9d6f)\n\n\n## MacOS swift app-agent\n\nIf you ask for something faster than [Raycast](https://github.com/egovelox/mozeidon/tree/main?tab=readme-ov-file#raycast-extension) ( which I find quite slow to trigger the search list ),  \nyou might take a look at this macOS app [mozeidon-macos-ui](https://github.com/egovelox/mozeidon-macos-ui)\n\n\u003cimg width=\"640\" alt=\"mozeidon-macos-ui\" src=\"https://github.com/user-attachments/assets/8590a296-3a4d-4287-b362-83804893710e\" /\u003e\n\n\n## Releases\n\nVarious releases of the Mozeidon CLI can be found on the [releases page](https://github.com/egovelox/mozeidon/releases).\n\nReleases are managed with github-actions and [goreleaser](https://github.com/goreleaser/goreleaser).\n\nA release will be auto-published when a new git tag is pushed,\ne.g :\n\n```bash\ngit clone https://github.com/egovelox/mozeidon.git \u0026\u0026 cd mozeidon;\n\ngit tag -a v2.0.0 -m \"A new mozeidon (CLI) release\"\n\ngit push origin v2.0.0\n```\n\n## Local development setup\n\nWe'll assume that you installed and followed the steps described in the `Mozeidon native-app` paragraph above.\nIn fact, you rarely need to modify this component, it's just a message broker (see the `architecture` paragraph above ).\n\nFirst clone this repository.\n\nThen, build the firefox-extension locally :\n\n```bash\ncd mozeidon/firefox-addon; npm install; npm run build\n```\n\nNow don't forget to disable the current mozeidon extension, if it is enabled in your browser.  \n\nThen, in Firefox, via `Extensions \u003e Debug Addons \u003e Load Temporary Add-on`, select the manifest file in `firefox-addon/manifest.json`.  \nThis will load the local extension into Firefox.\n\nFrom there, you may want to go further and build the CLI also :\n\n```bash\ncd mozeidon/cli; go build;\n```\n\nYou should now be able to use the CLI with the local binary :\n\n```bash\n./mozeidon/cli/mozeidon tabs get\n```\n\n## Notes\n\nFor users who installed both the firefox-addon AND the chrome-addon, \n`mozeidon` CLI will not work properly when both browser-extensions are activated at the same time.\nTo overcome this limitation, keep one extension activated (e.g firefox-addon) and deactivate the other extension (e.g chrome-addon).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fegovelox%2Fmozeidon","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fegovelox%2Fmozeidon","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fegovelox%2Fmozeidon/lists"}