{"id":32789837,"url":"https://github.com/tom88115/chrome-bookmark","last_synced_at":"2026-04-30T12:33:35.984Z","repository":{"id":321033033,"uuid":"1084194053","full_name":"tom88115/chrome-bookmark","owner":"tom88115","description":"🔖 智能书签同步工具 - 支持 Chrome 和 Atlas 浏览器之间的书签同步，保持顺序，自动备份","archived":false,"fork":false,"pushed_at":"2025-10-27T11:00:13.000Z","size":30,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-04-30T12:33:35.259Z","etag":null,"topics":["atlas","automation","bookmark","browser","chrome","macos","python","sync"],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/tom88115.png","metadata":{"files":{"readme":"README-GITHUB.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-10-27T10:58:37.000Z","updated_at":"2025-10-27T11:00:17.000Z","dependencies_parsed_at":"2025-11-05T11:02:17.938Z","dependency_job_id":null,"html_url":"https://github.com/tom88115/chrome-bookmark","commit_stats":null,"previous_names":["tom88115/chrome-bookmark"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/tom88115/chrome-bookmark","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tom88115%2Fchrome-bookmark","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tom88115%2Fchrome-bookmark/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tom88115%2Fchrome-bookmark/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tom88115%2Fchrome-bookmark/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tom88115","download_url":"https://codeload.github.com/tom88115/chrome-bookmark/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tom88115%2Fchrome-bookmark/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32465009,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-29T22:27:22.272Z","status":"online","status_checked_at":"2026-04-30T02:00:05.929Z","response_time":57,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["atlas","automation","bookmark","browser","chrome","macos","python","sync"],"created_at":"2025-11-05T11:01:16.031Z","updated_at":"2026-04-30T12:33:35.977Z","avatar_url":"https://github.com/tom88115.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# 🔖 Chrome \u0026 Atlas 书签同步工具\n\n一个智能的浏览器书签同步工具，支持在 Google Chrome 和 OpenAI Atlas 浏览器之间同步书签。采用保守策略，只添加缺失的书签，保持原有顺序不变。\n\n![macOS](https://img.shields.io/badge/macOS-000000?style=flat\u0026logo=apple\u0026logoColor=white)\n![Python](https://img.shields.io/badge/Python-3.x-blue?style=flat\u0026logo=python\u0026logoColor=white)\n![License](https://img.shields.io/badge/License-MIT-green?style=flat)\n\n---\n\n## ✨ 功能特性\n\n- ✅ **智能同步** - 自动检测 Atlas 新书签并同步到 Chrome\n- ✅ **保持顺序** - 不改变原有书签的顺序\n- ✅ **避免重复** - 相同书签不会重复添加\n- ✅ **自动备份** - 每次同步前自动备份两个浏览器的书签\n- ✅ **文件夹支持** - 保持书签文件夹结构\n- ✅ **多种启动方式** - Spotlight、双击、快捷键、终端命令\n- ✅ **详细日志** - 记录每次同步的详细信息\n- ✅ **安全可靠** - 不修改 Atlas 书签，单向同步更安全\n\n---\n\n## 🎯 使用场景\n\n这个工具适合：\n\n- 你主要在 Atlas 浏览器添加和管理书签\n- 偶尔需要在 Chrome 访问相同的书签\n- 不想书签顺序被打乱\n- 需要在两个浏览器之间保持书签同步\n\n---\n\n## 📦 安装\n\n### 前置要求\n\n- macOS 10.13 或更高版本\n- Python 3.x（macOS 自带）\n- Google Chrome 浏览器\n- OpenAI Atlas 浏览器\n\n### 克隆仓库\n\n```bash\ngit clone https://github.com/你的用户名/chrome-bookmark.git\ncd chrome-bookmark\n```\n\n### 设置权限\n\n```bash\nchmod +x *.sh *.py\n```\n\n---\n\n## 🚀 快速开始\n\n### 方法 1：创建 macOS 应用（推荐）\n\n运行创建脚本，生成可以在 Spotlight 搜索的应用：\n\n```bash\n./create_app.sh\n```\n\n创建成功后：\n1. 按 `Cmd + Space` 打开 Spotlight\n2. 输入 `书签同步`\n3. 按回车运行\n\n### 方法 2：使用便捷脚本\n\n```bash\n./同步到Chrome.sh\n```\n\n### 方法 3：直接运行 Python 脚本\n\n```bash\npython3 sync_bookmarks_v2.py\n```\n\n---\n\n## 📱 使用方式\n\n### 🔍 Spotlight 搜索（最推荐）\n\n1. 先运行 `./create_app.sh` 创建应用\n2. 按 `Cmd + Space`\n3. 输入 `书签同步` 或 `bookmark`\n4. 按回车\n\n### 🖱️ 双击运行\n\n创建应用后，可以在以下位置找到：\n- `~/Applications/书签同步工具.app`\n- `~/Desktop/书签同步工具.app`（桌面快捷方式）\n\n### ⌨️ 终端运行\n\n```bash\n# 使用快捷脚本\n./同步到Chrome.sh\n\n# 或直接运行 Python\npython3 sync_bookmarks_v2.py\n\n# 创建别名（可选）\necho 'alias sync-bookmark=\"python3 ~/path/to/sync_bookmarks_v2.py\"' \u003e\u003e ~/.zshrc\nsource ~/.zshrc\n```\n\n---\n\n## 🎬 工作原理\n\n```\n┌─────────────┐         ┌─────────────┐\n│   Atlas     │         │   Chrome    │\n│  (源书签)   │         │  (目标)     │\n└──────┬──────┘         └──────┬──────┘\n       │                       │\n       │  ① 读取书签           │\n       ├───────────────────────┤\n       │                       │\n       │  ② 查找 Chrome        │\n       │     没有的书签        │\n       │                       │\n       │  ③ 添加新书签         │\n       │     (保持原有顺序)    │\n       │                       │\n       ├───────────────────────┤\n       │                       │\n   不修改 ✓                 已更新 ✓\n```\n\n### 同步逻辑\n\n1. **扫描** - 读取 Atlas 和 Chrome 的书签文件\n2. **比较** - 找出 Atlas 有但 Chrome 没有的书签\n3. **添加** - 将新书签添加到 Chrome（保持文件夹结构）\n4. **保护** - 不修改 Atlas，不改变 Chrome 原有书签顺序\n\n---\n\n## 📂 项目结构\n\n```\nchrome-bookmark/\n├── sync_bookmarks_v2.py      # V2 核心同步脚本\n├── 同步到Chrome.sh             # 快速运行脚本\n├── create_app.sh              # 创建 macOS 应用\n├── setup_auto_sync.sh         # 设置自动同步（定时任务）\n│\n├── README-GITHUB.md           # 项目说明（本文件）\n├── 使用说明-V2.md              # 详细使用文档\n├── 快速开始.md                 # 新手指南\n├── 快速启动指南.md             # 启动方式说明\n├── 故障排查.md                 # 问题解决\n│\n└── sync_bookmarks.py          # V1 旧版本（不推荐使用）\n```\n\n---\n\n## 🛡️ 安全保障\n\n### 自动备份\n\n每次同步前自动备份：\n```\n~/bookmark-sync-backups/\n├── chrome_bookmarks_时间戳.json\n├── atlas_bookmarks_时间戳.json\n└── sync_v2.log\n```\n\n### 恢复备份\n\n如果出现问题，可以从备份恢复：\n\n```bash\n# 查看备份\nls -lt ~/bookmark-sync-backups/\n\n# 恢复 Chrome 书签\ncp ~/bookmark-sync-backups/chrome_bookmarks_时间戳.json \\\n   ~/Library/Application\\ Support/Google/Chrome/Default/Bookmarks\n\n# 重启 Chrome\n```\n\n---\n\n## ⚙️ 配置说明\n\n### 修改 Atlas 书签路径\n\n如果脚本找不到 Atlas 书签，编辑 `sync_bookmarks_v2.py`：\n\n```python\nself.atlas_path = Path.home() / \"你的实际路径/Bookmarks\"\n```\n\n### 设置自动同步\n\n运行设置脚本，每小时自动同步：\n\n```bash\n./setup_auto_sync.sh\n```\n\n管理定时任务：\n\n```bash\n# 停止\nlaunchctl unload ~/Library/LaunchAgents/com.bookmarksync.plist\n\n# 启动\nlaunchctl load ~/Library/LaunchAgents/com.bookmarksync.plist\n\n# 查看状态\nlaunchctl list | grep bookmarksync\n```\n\n---\n\n## 📊 同步示例\n\n### 运行输出\n\n```\n============================================================\n  🔖 书签同步工具 V2\n  Atlas → Chrome\n============================================================\n\n✓ Chrome: Bookmarks\n✓ Atlas: Bookmarks\n\n📦 创建备份...\n✓ 已备份 chrome: chrome_bookmarks_20251027_173855.json\n✓ 已备份 atlas: atlas_bookmarks_20251027_173855.json\n\n📖 加载书签...\n\n🔍 发现 3 个新书签需要添加到 Chrome：\n  ✓ [1] GitHub - Feishu-MCP\n      位置: 书签栏/AI\n  ✓ [2] 16软著 - 飞书云文档\n      位置: 书签栏\n  ✓ [3] gateway.zeabur.cn\n      位置: 书签栏\n\n💾 保存更新...\n✓ 已保存书签: Bookmarks\n\n============================================================\n✅ 同步完成！已添加 3 个新书签到 Chrome\n============================================================\n```\n\n---\n\n## ❓ 常见问题\n\n### Q1: 同步后 Chrome 没有显示新书签？\n\n**A:** 必须完全退出 Chrome（`Cmd + Q`），然后重新打开。浏览器会缓存书签文件。\n\n---\n\n### Q2: Atlas 的书签会被修改吗？\n\n**A:** 不会。V2 版本完全不修改 Atlas 的书签文件，只读取。\n\n---\n\n### Q3: 会不会删除我的书签？\n\n**A:** 不会。脚本只会**添加**新书签，不会删除或修改现有书签。\n\n---\n\n### Q4: 如果我在 Chrome 也添加了书签怎么办？\n\n**A:** Chrome 的新书签会保留，不会被删除。但不会自动同步到 Atlas（单向同步）。\n\n---\n\n### Q5: 支持 Windows 或 Linux 吗？\n\n**A:** 目前只支持 macOS。因为：\n- 使用了 macOS 特定的路径\n- Spotlight 集成是 macOS 专属\n- Atlas 浏览器路径是 macOS 格式\n\n如需支持其他平台，需要修改路径配置。\n\n---\n\n## 🔧 故障排查\n\n### 找不到 Atlas 书签文件\n\n**解决方法：**\n\n1. 手动查找：\n   ```bash\n   find ~/Library/Application\\ Support -name \"Bookmarks\" 2\u003e/dev/null\n   ```\n\n2. 编辑脚本添加实际路径（见\"配置说明\"）\n\n### macOS 安全警告\n\n**第一次运行可能提示：**\n```\n\"书签同步工具\"无法打开，因为无法验证开发者\n```\n\n**解决：**\n```bash\nxattr -d com.apple.quarantine ~/Applications/书签同步工具.app\n```\n\n或右键点击应用 → 选择\"打开\" → 在弹窗中点击\"打开\"\n\n---\n\n## 📖 文档\n\n- [使用说明-V2.md](使用说明-V2.md) - 完整使用手册\n- [快速开始.md](快速开始.md) - 新手快速入门\n- [快速启动指南.md](快速启动指南.md) - 各种启动方式详解\n- [故障排查.md](故障排查.md) - 问题解决大全\n\n---\n\n## 🤝 贡献\n\n欢迎提交 Issue 和 Pull Request！\n\n如果你有好的想法或发现了 Bug，请：\n\n1. Fork 本仓库\n2. 创建你的特性分支 (`git checkout -b feature/AmazingFeature`)\n3. 提交你的修改 (`git commit -m 'Add some AmazingFeature'`)\n4. 推送到分支 (`git push origin feature/AmazingFeature`)\n5. 打开 Pull Request\n\n---\n\n## 📋 更新日志\n\n### v2.0.0 (2025-10-27)\n\n- ✨ V2 版本重新设计\n- ✅ 采用保守单向同步策略\n- ✅ 保持书签原有顺序\n- ✅ 不修改 Atlas 书签\n- ✅ 支持 macOS 应用形式\n- ✅ 集成 Spotlight 搜索\n- ✅ 自动备份功能\n- ✅ 详细的同步日志\n\n### v1.0.0 (2025-10-27)\n\n- 初始版本\n- 双向合并同步（已弃用）\n\n---\n\n## 📄 许可证\n\nMIT License\n\nCopyright (c) 2025\n\n---\n\n## 🌟 Star History\n\n如果这个项目对你有帮助，请给个 Star ⭐！\n\n---\n\n## 📞 联系方式\n\n- 问题反馈：[GitHub Issues](https://github.com/你的用户名/chrome-bookmark/issues)\n- 功能建议：[GitHub Discussions](https://github.com/你的用户名/chrome-bookmark/discussions)\n\n---\n\n## 🙏 致谢\n\n感谢所有使用和贡献这个项目的人！\n\n---\n\n**祝使用愉快！** 🎉\n\n如果觉得有用，别忘了给个 Star ⭐\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftom88115%2Fchrome-bookmark","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftom88115%2Fchrome-bookmark","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftom88115%2Fchrome-bookmark/lists"}