From 244c0493eac212889a18cf5116381be71194d2e3 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Mon, 20 Jul 2026 21:04:56 +0000 Subject: [PATCH] docs: update Learning Hub for CLI v1.0.71-v1.0.72 changes - automating-with-hooks: document stop_hook_active flag for agentStop hooks (v1.0.72) so users know to self-limit blocking hooks - creating-effective-skills: add copilot plugins install --skill command including --scope project flag for repo-scoped installs (v1.0.72) - installing-and-using-plugins: document expanded /plugins slash command management (update, uninstall, enable, disable with --plugin/--mcp/ --skill flags) and marketplace management commands (v1.0.71-v1.0.72) Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- .../learning-hub/automating-with-hooks.md | 19 +++++++- .../learning-hub/creating-effective-skills.md | 15 ++++++- .../installing-and-using-plugins.md | 44 ++++++++++++++++++- 3 files changed, 75 insertions(+), 3 deletions(-) diff --git a/website/src/content/docs/learning-hub/automating-with-hooks.md b/website/src/content/docs/learning-hub/automating-with-hooks.md index 8864598f..87a22f37 100644 --- a/website/src/content/docs/learning-hub/automating-with-hooks.md +++ b/website/src/content/docs/learning-hub/automating-with-hooks.md @@ -3,7 +3,7 @@ title: 'Automating with Hooks' description: 'Learn how to use hooks to automate lifecycle events like formatting, linting, and governance checks during Copilot agent sessions.' authors: - GitHub Copilot Learning Hub Team -lastUpdated: 2026-07-13 +lastUpdated: 2026-07-20 estimatedReadingTime: '8 minutes' tags: - hooks @@ -369,6 +369,23 @@ Run ESLint after the agent finishes responding and block if there are errors: If the lint command exits with a non-zero status, the action is blocked. +> **`stop_hook_active` flag (v1.0.72+)**: If an `agentStop` hook always blocks (returns non-zero), the CLI ends the turn after **8 consecutive blocks** instead of looping indefinitely. When this happens, the hook receives a `stop_hook_active: true` field in its JSON input so it can detect the forced continuation and self-limit — for example, by skipping the blocking check or logging a warning instead. This prevents infinite loops caused by hooks that unconditionally deny completion. + +```bash +#!/usr/bin/env bash +# scripts/final-lint.sh +INPUT=$(cat) +STOP_HOOK_ACTIVE=$(echo "$INPUT" | jq -r '.stop_hook_active // false') + +# Self-limit when the CLI has hit the 8-block threshold +if [ "$STOP_HOOK_ACTIVE" = "true" ]; then + echo "Warning: agentStop hook reached block limit — skipping lint." >&2 + exit 0 +fi + +npx eslint . --max-warnings 0 +``` + ### Security Gating with preToolUse Block dangerous commands before they execute. Use the `matcher` field to target only the `bash` tool, so the hook doesn't fire for file edits or other tools: diff --git a/website/src/content/docs/learning-hub/creating-effective-skills.md b/website/src/content/docs/learning-hub/creating-effective-skills.md index d9ba88a4..66c3f955 100644 --- a/website/src/content/docs/learning-hub/creating-effective-skills.md +++ b/website/src/content/docs/learning-hub/creating-effective-skills.md @@ -3,7 +3,7 @@ title: 'Creating Effective Skills' description: 'Master the art of writing reusable, shareable skill folders that deliver consistent results across your team.' authors: - GitHub Copilot Learning Hub Team -lastUpdated: 2026-07-13 +lastUpdated: 2026-07-20 estimatedReadingTime: '9 minutes' tags: - skills @@ -381,6 +381,19 @@ copilot skill add https://example.com/skill.zip # add a skill from a URL copilot skill remove my-skill # remove an installed skill by name ``` +You can also install skills via the `copilot plugins install` command (v1.0.72+): + +```bash +# Install a skill from a local directory, URL, or file +copilot plugins install --skill ./my-skill/ +copilot plugins install --skill https://example.com/skill.zip + +# Install into the current repository (project scope) instead of globally +copilot plugins install --skill ./my-skill/ --scope project +``` + +The `--scope project` flag installs the skill into the repository's `.github/skills/` directory — useful when you want the skill checked into version control and shared with the whole team rather than installed only for your user. + You can also run `/skill` (or the existing `/skills`) inside an interactive session to see what's loaded. The `copilot skill` subcommand is the recommended way to install skills that aren't packaged inside a plugin. **Q: How are skills different from prompts?** diff --git a/website/src/content/docs/learning-hub/installing-and-using-plugins.md b/website/src/content/docs/learning-hub/installing-and-using-plugins.md index 4733a4ba..3517d680 100644 --- a/website/src/content/docs/learning-hub/installing-and-using-plugins.md +++ b/website/src/content/docs/learning-hub/installing-and-using-plugins.md @@ -3,7 +3,7 @@ title: 'Installing and Using Plugins' description: 'Learn how to find, install, and manage plugins that extend GitHub Copilot CLI with reusable agents, skills, hooks, and integrations.' authors: - GitHub Copilot Learning Hub Team -lastUpdated: 2026-07-13 +lastUpdated: 2026-07-20 estimatedReadingTime: '8 minutes' tags: - plugins @@ -222,6 +222,48 @@ copilot plugin marketplace update copilot plugin uninstall my-plugin ``` +### Managing Plugins, Skills, and MCP Servers via Slash Commands + +*(v1.0.71–v1.0.72+)* Inside an interactive Copilot session, the `/plugins` slash command now supports the full range of management actions. You can target plugins, MCP servers, or skills using explicit flags: + +``` +# Plugin management +/plugins update my-plugin +/plugins uninstall my-plugin +/plugins enable my-plugin +/plugins disable my-plugin + +# Skill management via /plugins +/plugins install --skill ./my-skill/ +/plugins remove --skill my-skill +/plugins enable --skill my-skill +/plugins disable --skill my-skill + +# MCP server management via /plugins +/plugins enable --mcp my-server +/plugins disable --mcp my-server +/plugins remove --mcp my-server +``` + +Use `/plugins help` inside a session to see all available subcommands. + +### Marketplace Management + +Manage plugin marketplaces from within a session or the CLI: + +``` +# From an interactive session +/plugins marketplace browse awesome-copilot +/plugins marketplace update # refresh all marketplace catalogs + +# From the CLI +copilot plugins marketplace list +copilot plugins marketplace browse awesome-copilot +copilot plugins marketplace update +copilot plugins marketplace add my-org/internal-plugins +copilot plugins marketplace remove my-org/internal-plugins +``` + ### Loading Plugins from a Local Directory You can load plugins directly from a local directory without installing them from a marketplace, using the `--plugin-dir` flag when starting Copilot: