ruff

安装方式
CLI
npx skills add https://github.com/astral-sh/claude-code-plugins --skill ruff

使用 CLI 安装这个技能,并在你的工作区中直接复用对应的 SKILL.md 工作流。

最后更新于 4/22/2026

Astral plugins for Claude Code

Installation

Add the marketplace

Add the Astral marketplace to Claude Code:

/plugin marketplace add astral-sh/claude-code-plugins

Install the astral plugin

After adding the marketplace:

/plugin install astral@astral-sh

Or browse and install interactively:

/plugin

Team installation

For team-wide plugin usage, add to your project's .claude/settings.json:

{
  "extraKnownMarketplaces": {
    "astral-sh": {
      "source": {
        "source": "github",
        "repo": "astral-sh/claude-code-plugins"
      }
    }
  },
  "enabledPlugins": {
    "astral@astral-sh": true
  }
}

Team members will be prompted to install the plugin when they trust the
repository.

Usage

Skills

The plugin provides skills for Astral tools.

Invoke skills with /astral:<skill>, e.g., /astral:uv.

Claude sometimes needs to be prompted to use skills. We recommend adding this
instruction to your CLAUDE.md:

When working with Python, invoke the relevant /astral:<skill> for uv,
ty, and ruff to ensure best practices are followed.

LSP

The plugin also provides the ty LSP. It requires uvx to be available.

License

Licensed under either of:

at your option.

Contributing

See CONTRIBUTING.md for development setup and guidelines.

Unless you explicitly state otherwise, any contribution intentionally submitted
for inclusion in the work by you, as defined in the Apache-2.0 license, shall be
dual licensed as above, without any additional terms or conditions.