Token导航 LogoToken导航TokenDH.com
研究检索external-servicegithub未标认证来源可访问许可证需确认审计提醒

sync-provider同步提供者

Agent Skill

sync-provider 用于查找、检索和筛选相关信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

1,297

周安装

53

GitHub Stars

323

下载量

420
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

unknown

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:sync-provider(同步提供者)
来源仓库:https://github.com/pedronauck/skills
仓库路径:skills/sync-provider
安装命令:
npx skills add https://github.com/pedronauck/skills --skill sync-provider
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/pedronauck/skills --skill sync-provider

简介

用于在 Codex、Claude、Cursor、Gemini CLI 中查找和筛选相关信息。

  • 支持根据关键词、任务场景或来源线索快速定位候选结果。
  • 可结合原始 README 和仓库内容进一步核验具体用法。
  • 安装前建议确认权限范围和维护状态,避免触发不必要操作。
  • 安装方式:通过 GitHub 仓库使用 npx 命令添加。

SKILL.md

Sync Provider

Sync changes from cloned provider repositories while preserving local customizations.

Overview

Most providers (except opencode) are cloned from external repositories and need to be kept in sync with upstream changes. This skill guides the complete workflow from checking for updates to applying changes safely.

Prerequisites

  1. GitHub CLI (gh): Must be installed and authenticated gh --version gh auth login gh auth status
  2. GitHub Token: Add GITHUB_TOKEN to root .env file GITHUB_TOKEN=your_token_here
  3. Repository Info: Each provider's package.json contains repository.url field (format: https://github.com/owner/repo-name)

Workflow

Step 1: Identify Provider and Repository

Check the provider's package.json for repository URL:

cat providers/<provider>/package.json | grep -A 2 repository

Extract owner/repo format: https://github.com/owner/repo-nameowner/repo-name

Step 2: Check for New Commits

Use check-provider-commit.sh to automatically check for new commits:

COMMIT_HASH=$(scripts/check-provider-commit.sh <provider> 2>/dev/null)
EXIT_CODE=$?

if [ $EXIT_CODE -eq 0 ] && [ -n "$COMMIT_HASH" ]; then
  echo "Proceeding with sync from commit: $COMMIT_HASH"
elif [ $EXIT_CODE -eq 0 ]; then
  echo "Already up to date - no sync needed"
  exit 0
else
  echo "No state file found - need to determine initial commit hash manually"
  exit 1
fi

Script Behavior:

  • Up to date: Exits with code 0, shows "Already up to date"
  • New commits: Outputs commit hash (last synced), exits with code 0
  • No state file: Exits with code 1, shows latest commit (requires manual determination for first sync)

Important: Redirect stderr (2>/dev/null) when capturing commit hash to avoid mixing informational messages.

Step 3: Run Git Diff Script

Execute the sync script with appropriate parameters:

REPO=$(cat providers/<provider>/package.json | grep -A 2 repository | grep url | cut -d'"' -f4 | sed 's|https://github.com/||')

pnpm exec tsx scripts/git-diff.ts \
  -r $REPO \
  -c "$COMMIT_HASH" \
  -i "src/**/*" \
  -i "docs/**/*" \
  -i "examples/**/*" \
  --state-file-path ./providers/<provider>/diff_last_commit.txt

Parameters:

  • -r, --repo: GitHub repository in owner/repo format (required)
  • -c, --commit: Commit hash to compare from (required) - use last synced commit from state file
  • -i, --include: Glob pattern(s) to filter files (can specify multiple times)

- Always use these three default patterns: - src/**/* - All source files - docs/**/* - Documentation files - examples/**/* - Example files

  • --state-file-path: Path to store last synced commit hash

Step 4: Deep Research and Analysis

MANDATORY: Before applying any changes, perform deep research:

# List all generated diff files
ls -R .diffs/<commit_hash>/

# Review all diffs to understand scope
find .diffs/<commit_hash>/ -name "*.txt" -exec echo "=== {} ===" \; -exec cat {} \;

# Get list of affected files
find .diffs/<commit_hash>/ -name "*.txt" | sed "s|\.diffs/<commit_hash>/||" | sed 's|\.txt$||'

Research Steps:

  1. Analyze All Diffs: Review every diff file to understand:

- Files being modified, added, or removed - Nature of changes (bug fixes, features, refactoring, breaking changes) - Impact on existing local customizations - Dependencies between changes

  1. Check Local Customizations: Review current local files to identify:

- Custom modifications that might conflict - Local additions that should be preserved - Configuration differences

  1. Review Project Rules: MANDATORY STEP - Check .cursor/rules to understand:

- Which rules apply to this provider (TypeScript, React, etc.) - Project standards and patterns - Best practices for the technologies involved

Step 5: Create Refactoring Plan Using Pal MCP

MANDATORY: Use Pal MCP refactor tool with Gemini 3.0 Pro to create comprehensive plan.

Refactor Tool Usage:

  1. Identify Relevant Files: Collect all files that will be affected:

- Files from .diffs/<commit_hash>/ that have changes - Current local files in providers/<provider>/ that correspond to changed files - Use FULL absolute paths for all files

  1. Run Pal Refactor Analysis: // Use mcp_zen_refactor with: // - model: "gemini-3.0-pro" or "anthropic/claude-opus-4.6" // - relevant_files: Array of absolute paths to affected files // - refactor_type: "modernize" or "organization" (as appropriate) // - focus_areas: ["sync-upstream-changes", "preserve-local-customizations"]
  2. Complete ALL Steps: MANDATORY - Finalize ALL steps until next_step_required: false

- Continue calling the refactor tool until you receive confirmation that all steps are complete - Do NOT proceed to any file edits until this is confirmed - TASK WILL BE INVALIDATED if you skip this step

  1. Review Refactoring Recommendations: The tool will provide:

- Best approach for applying changes - How to preserve local customizations - Potential conflicts and how to resolve them - Code quality improvements - Architecture considerations

Refactor Tool Requirements:

  • Model: Must use gemini-3.0-pro or anthropic/claude-opus-4.6
  • Multi-step: Complete ALL steps until next_step_required: false - NO EXCEPTIONS
  • File Paths: Use FULL absolute paths (e.g., /Users/pedronauck/Dev/compozy/compozy-code/providers/claude-code/src/index.ts)
  • Focus Areas: Include context about syncing upstream changes while preserving local customizations
  • Completion Verification: Only proceed when the tool confirms all steps are complete

Step 6: Create Implementation Plan

Based on the Pal refactor analysis, create detailed implementation plan:

  1. Prioritize Changes: Order by dependencies (apply dependencies first), risk level (low-risk first), impact (critical files first)
  2. Identify Conflicts: Document files with local customizations that conflict with upstream changes, strategy for resolving each conflict, decisions on what to preserve vs. update
  3. Plan Testing Strategy: Define which tests to run after each change, how to verify local customizations are preserved, integration points to test
  4. Document Decisions: Record why certain changes are applied or skipped, how local customizations are preserved, any architectural decisions made

Step 7: Apply Changes According to Plan

Only after completing steps 4-6 AND verifying Pal Refactor completion, apply changes:

  1. For Modified Files: Apply changes according to refactor plan, preserving local customizations
  2. For Added Files: Add new files following project standards
  3. For Removed Files: Evaluate if removal should be applied locally (may need to preserve)
  4. For Renamed Files: Handle rename and content changes according to plan

Best Practices:

  • Apply changes incrementally, following the prioritized plan
  • Test after each significant change
  • Preserve local customizations as identified in the plan
  • Document any deviations from the plan

Step 8: Update State File

After successfully applying changes, verify state file was updated:

cat providers/<provider>/diff_last_commit.txt
# Should contain the latest commit hash that was synced

Example Workflow

Syncing claude-code Provider

# 1. Check repository info
cat providers/claude-code/package.json | grep repository

# 2. Check for new commits
COMMIT_HASH=$(scripts/check-provider-commit.sh claude-code 2>/dev/null)
EXIT_CODE=$?

if [ $EXIT_CODE -ne 0 ]; then
  echo "⚠️  No state file found - need to determine initial commit hash manually"
  exit 1
elif [ -z "$COMMIT_HASH" ]; then
  echo "✅ Already up to date - no sync needed"
  exit 0
fi

# 3. Extract repository name
REPO=$(cat providers/claude-code/package.json | grep -A 2 repository | grep url | cut -d'"' -f4 | sed 's|https://github.com/||')

# 4. Run sync script
pnpm exec tsx scripts/git-diff.ts \
  -r $REPO \
  -c "$COMMIT_HASH" \
  -i "src/**/*" \
  -i "docs/**/*" \
  -i "examples/**/*" \
  --state-file-path ./providers/claude-code/diff_last_commit.txt

# 5. Deep research and analysis
find .diffs/$COMMIT_HASH/ -name "*.txt" -exec echo "=== {} ===" \; -exec cat {} \;

# 6. Use Pal MCP refactor tool (complete all steps)
# 7. Create implementation plan
# 8. Apply changes according to plan
# 9. Verify state file updated
cat providers/claude-code/diff_last_commit.txt

Available Providers

ProviderRepositoryNotes
claude-codeben-vargas/ai-sdk-provider-claude-codeCloned
geminiben-vargas/ai-sdk-provider-gemini-cliCloned
codexben-vargas/ai-sdk-provider-codex-cliCloned
opencodeN/ACreated locally - no sync needed

Critical Requirements

Troubleshooting

No files matching glob pattern

  • Check if the commit hash is correct
  • Verify the repository name format
  • Use broader patterns like **/* to see all changes

State file not found

  • First sync: Use the initial commit hash from when you cloned
  • Subsequent syncs: The script creates the state file automatically

Binary files detected

Binary files are noted in .diffs/<commit_hash>/<file-path>.txt but not diffed. Handle these manually:

  • Images: Review in GitHub or download directly
  • Other binaries: Decide if update is needed

GitHub API rate limits

  • Wait before retrying
  • Use a GitHub token with higher rate limits
  • Consider syncing in smaller batches

After Syncing

  • MUST TEST: Run tests in the provider directory: cd providers/<provider> pnpm test pnpm run lint pnpm run typecheck
  • MUST VERIFY: Ensure all changes are correctly applied and no local customizations are lost
  • MUST DOCUMENT: Record any decisions made during the sync process, especially:

- Conflicts resolved - Local customizations preserved - Deviations from upstream changes - Architectural decisions

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Codex

36.5%
按下载量换算153

Claude

28.75%
按下载量换算121

Cursor

19.86%
按下载量换算83

Gemini CLI

10%
按下载量换算42

安全审计

Gen Agent Trust Hub

可疑

Socket

可疑

Snyk

可疑

权限和风险

external-service

该 Skill 可能调用第三方服务、云服务或外部模型 API,使用前需要确认账号、额度、数据发送范围和服务条款。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。来源安全扫描存在 warning/failed 结果,不能写成本站确认安全。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills