Skip to content
skiluoPublic

About

CLI tools collection.

Resources

Stars

2 stars

Watchers

0 watching

Forks

Latest commit

 

History

4 Commits

Folders and files

Repository files navigation

tools-cli

CLI tools collection.

Current focus

This repository currently focuses on export-browser-cookies, a macOS CLI workflow for exporting cookies from Chromium-based browsers and optionally importing them into local automation tools.

export-browser-cookies

What it does

  • Reads non-expired cookies from your local browser profile
  • Decrypts cookie values via macOS Keychain
  • Optionally filters by exact domain (host_key)
  • Exports cookies as JSON to stdout
  • Optionally imports cookies into agent-browser or pinchtab

Supported browsers

  • Comet (aliases: comet, perplexity)
  • Chrome (aliases: chrome, google-chrome)
  • Arc (alias: arc)
  • Brave (alias: brave)
  • Edge (alias: edge)

Prerequisites

  • macOS
  • Go 1.19+
  • Access to macOS Keychain

Build

cd export-browser-cookies/scripts
go build -o export-cookies .

Command format

./export-cookies [--browser <name>] [--domain <domain1,domain2,...>] [--profile <profile>] [--import-by <target>] [--help]

Flags

  • --browser: Browser name or alias, default chrome
  • --domain: Comma-separated domains, exact match on cookie host_key
  • --profile: Browser profile directory, default Default
  • --import-by: Import target, supports agent-browser and pinchtab
  • --help / -h: Show usage

Examples

Export all non-expired cookies from Chrome:

cd export-browser-cookies/scripts
./export-cookies --browser chrome

Export only .github.com cookies:

./export-cookies --browser chrome --domain .github.com

Export from a non-default profile:

./export-cookies --browser edge --profile "Profile 1" --domain .github.com

Export and import into agent-browser:

./export-cookies --browser chrome --domain .github.com,github.com --import-by agent-browser

Export and import into pinchtab:

./export-cookies --browser chrome --domain .github.com --import-by pinchtab

Output behavior

  • Without --import-by: prints cookie JSON array to stdout
  • With --import-by: imports cookies and prints per-domain summary to stderr

Notes

  • On first run for a browser, macOS may show a Keychain permission dialog
  • If you need a file artifact, redirect output manually (for example > cookie.json)
  • Domain matching is exact, usually including a leading dot such as .github.com

About

CLI tools collection.

Resources

Stars

2 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages