Repository navigation
feat(skill): install the brevo-cli skill for Codex and Gemini CLI too - #138
Open
piyushsarin-sib wants to merge 10 commits into
Open
piyushsarin-sib wants to merge 10 commits into
piyushsarin-sib wants to merge 10 commits into
Conversation
`brevo skill:cli install --agent <claude|codex|gemini|all>` installs the skill into each agent's skills directory: ~/.claude/skills for Claude Code (the default, unchanged), ~/.agents/skills for Codex and Gemini CLI, which both read it, so one copy serves the two. - uninstall removes every copy the CLI installed, or one agent's with --agent - auto-refresh keeps every installed copy current - BREVO_AGENTS_HOME overrides ~/.agents, like BREVO_CLAUDE_HOME - --json results gain an `agents` field - SKILL.md, AGENTS.md, README and CLAUDE.md no longer call the skill Claude-only: it follows the open Agent Skills format these agents load Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…atalog (#140) * feat(skill): install, update and check skills from the brevo-skills catalog Replace the one-skill `skill:cli` group with `brevo skill install|update| uninstall|list|check`. Skills come from the brevo-skills catalog (latest release asset, or `--pin <release>`), are fetched from the release tag and hashed by the catalog's contract before they are written; a mismatch skips that skill and exits 1. Skills marked `default` are always included, platform fit and `min_cli_version` are honoured, `--mcp` registers the Brevo MCP server through each agent's own CLI, `--dry-run` writes nothing. Each installed directory carries `.brevo-skill.json`; `~/.brevo/skills.lock.json` records versions, releases and pins. The catalog is cached at `~/.brevo/skills-catalog.json`; after any command, when the cache is older than 12 hours and something is installed, outdated unpinned skills are reinstalled, silently on network failure. Offline, `skill install brevo-cli` installs the bundled copy. `skill:cli install|uninstall` stay as hidden aliases. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> * docs(skill): describe the skill command group in the README and agent docs Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> * fix(skill): refuse unsafe catalog paths and spawn agent CLIs by absolute path Catalog file and skill paths are validated as `/`-joined plain segments (letters, digits, dot, underscore, dash; never `.`, `..`, an empty segment, a backslash, a drive letter, a control character or the marker name), and the write site checks again: the resolved destination must stay under the skill directory and no component between the two may be a symbolic link. A refused file skips that skill, like a hash mismatch, and the run exits 1. `--mcp` resolves the agent CLI to an absolute path from absolute PATH entries only and spawns that path with no shell, so the OS performs no lookup of its own. On Windows only an `.exe` is run; a `.cmd`/`.bat` launcher needs a shell, so its command is printed instead. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> * feat(skill): print an update notice after commands instead of reinstalling skills After a brevo command, an installed skill that is behind the catalog is now named in one stderr line pointing to `brevo skill update`; nothing on disk changes. BREVO_SKILL_AUTOREFRESH=1 restores the reinstall, and BREVO_NO_SKILL_AUTOREFRESH=1 still turns the check off. The offline bundled copy follows the same rule. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> * fix(skill): call validateSkill through an arrow in map (Sonar S7727) Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> --------- Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
shubham773
previously approved these changes
Oct 15, 2026
CI sets CI=true, which makes the auto-refresh skip itself, so the tests now start from an environment without that gate. The PATHEXT test names its file with the upper-case extension so it also matches on a case-sensitive filesystem. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Remove the ASSUMPTION caveats that named internal tickets from agent-context/SKILL.md and agent-context/AGENTS.md. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
After a release publishes, dispatch getbrevo/brevo-skills' sync-skill workflow for brevo-cli at the release commit. That repo packages agent-context/SKILL.md for every agent platform and opens a PR there for review. Best-effort: skipped with a warning without BREVO_SKILLS_SYNC_TOKEN, and continue-on-error so it never fails a release. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2 tasks
Resolve conflicts with the public-apps GA docs (#143): keep the `brevo skill update` wording in CLAUDE.md, keep the ticket-free M2M lines in SKILL.md, and take main's new status/submit/withdraw entries. Drop the internal ticket keys that main reintroduced into agent-context/. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
…ill:cli When the catalog cannot be fetched, `brevo skill install` now says the brevo-skills repository is not reachable and points to the hidden `brevo skill:cli install` group, which installs only the CLI skill from the copy bundled with the CLI. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
… hand Move both post-publish steps into composite actions so the Release job and two new workflow_dispatch workflows (Sync brevo-skills, Bump Homebrew formula) run the same code. The release path keeps its behaviour and order (sync best-effort, Homebrew last, no extra approval); the manual workflows run in the npm-publish environment, so they need the same reviewer approval and only run from main. The Homebrew version is now validated before it is used in a URL, branch name and sed expression. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Resolve the README env var table: keep this PR's new rows in main's prettier-aligned layout. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
bump-homebrew.yml is now the single implementation: workflow_dispatch for a manual run, workflow_call for the Release workflow, which runs it as a separate job after a publish instead of a final step in the publish job. A failed bump no longer fails the release job and can be re-run alone. Drops the composite action and the netrc workaround that only the in-job step needed. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
|
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



What changed
brevo skill:cli installinstalled the agent skill for Claude Code only, and the skill told every other agent not to install it. The skill follows the open Agent Skills format, which Codex and Gemini CLI load too, so this PR lets the CLI install it for them.~/.agents/skills/(docs). Gemini CLI reads the same directory as an alias of~/.gemini/skills/and gives it precedence (docs).--agent codex,geminitherefore writes a single copy.uninstallremoves every copy the CLI installed, for any agent, or only the agents given with--agent. It still deletes only directories carrying the.brevo-skill.jsonmarker.BREVO_AGENTS_HOMEoverrides~/.agents/, the same wayBREVO_CLAUDE_HOMEoverrides~/.claude/.--json: install and uninstall results gain anagentsfield naming the agents that readpath. This only adds a field.--agent cursor) are refused with the list of valid values, before anything is written.Docs, kept in sync
agent-context/SKILL.md,agent-context/AGENTS.md, the README (env var table and the agent integration section) andCLAUDE.mdno longer describe the skill as Claude-only.AGENTS.mdnow branches by whether the agent loads skills from a directory, rather than Claude versus other agents.AGENTS.md.CLAUDE.mdasks to keep the skill's wording agent-neutral.Unrelated note: the README mentions a one-time skill-install banner (
~/.brevo/skill-banner.json), but I couldn't find it insrc/onmain. It's left untouched here.Behaviour that doesn't change
brevo skill:cli installwithout--agentinstalls exactly as before (Claude Code only). Existing installs keep their marker and keep auto-refreshing.Checks
parseSkillAgents,getAgentsSkillsRoot, installing into~/.agents, all agents,isInstalled, uninstall per agent and for all agents, auto-refresh of an~/.agentscopy, and the command-level--agenthandling. 1790 tests pass.yarn lintandyarn buildpass.brevo skill:cli install --agent all --jsonwrites both copies.🤖 Generated with Claude Code
Also in this PR: install from the brevo-skills catalog (from #140)
The
brevo skillcommand group replaces the one-skillskill:cligroup. Skills come from the brevo-skills catalog instead of only the copy bundled with the CLI.--agent claude,codex,gemini|all,--pin <release>,--mcp(registers the Brevo MCP server through each agent CLI, or prints the command),--force,--dry-run,--json./-joined segments (no.., backslash, drive letter or symlink on the way); an unsafe path skips the skill and exits 1.--mcpspawns the agent CLI by absolute path with no shell; on Windows only an.exeruns, a.cmd/.batlauncher is printed instead.min_cli_versionis newer than the CLI, or whose platforms exclude the agent, is skipped with a message..brevo-skill.json;~/.brevo/skills.lock.jsonrecords versions, releases and pins; the catalog is cached at~/.brevo/skills-catalog.json.BREVO_SKILL_AUTOREFRESH=1reinstalls them instead. Silent on network failure.brevo skill install brevo-cliinstalls the bundled copy.BREVO_SKILLS_CATALOG_URL,BREVO_SKILLS_FILES_URL.skill:cli install|uninstallstay as hidden aliases.--jsonresults now carrystatus(installed,updated,already-installed,skippedwithreason;removed,not-installed).Depends on
getbrevo/brevo-skillsbeing public. The catalog is read from that repo's release assets (releases/latest/download/catalog.json) and files fromraw.githubusercontent.com, so these commands only work for users once it is public and has a release.Also in this PR: brevo-skills sync trigger (was #139)
After a release publishes
@getbrevo/cli,release.yamldispatchessync-skillingetbrevo/brevo-skillsforbrevo-cliat the release commit. That repo opens a PR for review, so nothing reaches users without a merge there. Best-effort:continue-on-error, and without the token it only warns.Also runnable by hand, and Homebrew is its own job.
.github/actions/sync-brevo-skills) used by the Release job and by a new manual workflow: Actions → Sync brevo-skills → Run workflow (optionalref, defaults to the tip ofmain; fails loudly if the token is missing)..github/workflows/bump-homebrew.yml, which Release calls as a separatehomebrewjob after a publish. The same workflow has a Run workflow button (optionalversion, defaults to the latest on npm; validated before use). A failed bump no longer fails the release job and can be re-run alone.npm-publishenvironment, so they need the same reviewer approval as a release and only run frommain. Thehomebrewjob asks for its own approval after the publish, since it uses that environment'sHOMEBREW_TAP_TOKEN.main.Before this step can run:
BREVO_SKILLS_SYNC_TOKENto thenpm-publishenvironment (fine-grained token or GitHub App token,actions: writeongetbrevo/brevo-skillsonly)sync-skill.ymlis ongetbrevo/brevo-skillsdefault branch (it is)Also drops the internal ticket keys from
agent-context/(the public skill text).