Agent skill

safari-tabs

Interact with Safari browser tabs, reading list, bookmarks, and history via AppleScript. Use when the user asks to analyze, organize, summarize, deduplicate, close, export, or manage their Safari tabs. Also handles reading list, bookmarks, and history searches. Triggers include "my tabs", "open tabs", "Safari tabs", "clean up my browser", "what tabs do I have open", "organize my tabs", "too many tabs", "reading list", "bookmarks", "browser history", "export tabs". Requires macOS with Safari.

Stars 4
Forks 0

Install this agent skill to your Project

npx add-skill https://github.com/jacobrask/claude-skills/tree/main/skills/safari-tabs

SKILL.md

Safari Tabs

Safari browser management via AppleScript.

Key Scripts

Script Purpose
get_tabs.sh Get tabs with optional window filtering (TSV/markdown/JSON)
close_by_pattern.sh RECOMMENDED: Close tabs matching URL pattern
close_tabs.sh Close by window,tab index (advanced)
find_duplicates.sh Find/close duplicate tabs
domain_stats.sh Analyze tabs by domain
export_tabs_*.sh Export as JSON/CSV/markdown/HTML
get_reading_list.sh Export Reading List
get_bookmarks.sh Export bookmarks
search_history.sh Search history
open_urls.sh Open URLs from file/stdin

Getting Tabs

bash
get_tabs.sh                    # All tabs as TSV
get_tabs.sh markdown           # All tabs as markdown
get_tabs.sh -w 1 markdown      # Window 1 only
get_tabs.sh -m "term" markdown # Window containing "term"

Closing Tabs

Always use close_by_pattern.sh (finds tabs by URL regardless of position):

bash
close_by_pattern.sh "unique-url-substring"

# Examples
close_by_pattern.sh "adrianroselli.com"
close_by_pattern.sh "/article/css-has-guide"

Closes ALL matching tabs across all windows. Use unique substring.

Alternative: close by position (error-prone, avoid unless necessary):

bash
close_tabs.sh "1,5" "2,3"  # Window,tab pairs (1-indexed)

Analysis Workflow

  1. Fetch: get_tabs.sh markdown
  2. Analyze: group by domain, identify duplicates/clusters, flag stale content
  3. Report: stats, categorized list, suggestions
  4. Act: close with close_by_pattern.sh "url-substring"

Process-and-close pattern:

  1. Fetch tab
  2. Process it
  3. Close: close_by_pattern.sh "unique-url-part"
  4. Next tab

Export Formats

bash
export_tabs_markdown.sh [list|table|checklist|grouped]
export_tabs_json.sh
export_tabs_csv.sh
export_tabs_html.sh > bookmarks.html  # Importable format

Other Features

Duplicates: find_duplicates.sh [--close] Domain stats: domain_stats.sh Reading list: get_reading_list.sh [tsv|markdown|json] Bookmarks: get_bookmarks.sh [tree|flat|json] History: search_history.sh [term] [--days N] Open URLs: open_urls.sh urls.txt or pipe stdin

Privacy: Tab data stays local. Page content not accessed unless explicitly requested.

Expand your agent's capabilities with these related and highly-rated skills.

jacobrask/claude-skills

calendar

Interact with Apple Calendar via AppleScript. Use when the user asks to check calendar, view events, create events, manage schedule, find free time, or list calendars. Triggers include "my calendar", "my schedule", "calendar events", "create event", "add to calendar", "what's on my calendar", "free time", "available slots", "upcoming events", "today's events". Requires macOS with Calendar.app.

4 0
Explore
jacobrask/claude-skills

jmap-email

Enables JMAP email operations using Node.js and jmap-jam library. Use when working with JMAP email servers, FastMail, Cyrus IMAP, Stalwart Mail Server, or when user mentions email search, reading, sending, or mailbox management.

4 0
Explore
jacobrask/claude-skills

knowledge-base

Manage your personal knowledge base of curated resources, bookmarks, and excerpts. Triggers include "knowledge base", "kb", "add to knowledge", "add tabs to", "what do I have on", "what do we know about", "find resources about". Use with safari-tabs skill for bulk ingestion from Safari windows. Location is ~/knowledge/.

4 0
Explore
mattpocock/skills

edit-article

Edit and improve articles by restructuring sections, improving clarity, and tightening prose. Use when user wants to edit, revise, or improve an article draft.

111,310 9,758
Explore
mattpocock/skills

obsidian-vault

Search, create, and manage notes in the Obsidian vault with wikilinks and index notes. Use when user wants to find, create, or organize notes in Obsidian.

111,310 9,758
Explore
mattpocock/skills

setup-pre-commit

Set up Husky pre-commit hooks with lint-staged (Prettier), type checking, and tests in the current repo. Use when user wants to add pre-commit hooks, set up Husky, configure lint-staged, or add commit-time formatting/typechecking/testing.

111,310 9,758
Explore

Didn't find tool you were looking for?

Be as detailed as possible for better results