python-code-style

Enforce Python code style and type checks with ruff and mypy.

3|Updated Jan 8, 2026
One-click install
npx skills add https://github.com/DrLuggels/my_dhbw --skill python-code-style-drluggels
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: python-code-style
Source: https://github.com/DrLuggels/my_dhbw/tree/main/.claude/plugins/python-development/skills/python-code-style
Command: npx skills add https://github.com/DrLuggels/my_dhbw --skill python-code-style-drluggels

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill addresses the challenges of maintaining consistent, readable, and maintainable Python code by providing guidance and tools for code style, linting, formatting, naming conventions, and documentation standards.

Core Features & Use Cases

  • Automated Formatting: Configure and use tools like ruff to automatically format code, ensuring consistency across the project.
  • Linting and Static Analysis: Employ ruff and mypy to catch style violations, potential bugs, and type errors early in the development cycle.
  • Naming Conventions: Adhere to PEP 8 standards for clear and descriptive naming of variables, functions, classes, and constants.
  • Documentation Standards: Implement Google-style docstrings for all public APIs to improve code understanding and maintainability.
  • Use Case: When starting a new Python project or onboarding a new developer, use this skill to set up the project's pyproject.toml with ruff and mypy configurations, ensuring all code adheres to established standards from the beginning.

Quick Start

Configure your project's pyproject.toml file with ruff and mypy settings to enforce code style and type checking.

Frequently Asked Questions about python-code-style

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I configure ruff and mypy in pyproject.toml for Python code style enforcement?

To enforce Python code style, configure your project's pyproject.toml file with ruff and mypy settings to automate formatting, linting, and type checking. This setup ensures code adheres to established standards from the beginning.

What is the best way to automate Python code formatting and linting?

The best way to automate Python code formatting and linting is using ruff to automatically format code and catch style violations early. This ensures consistency and maintainability across your project.

Does this Python code style approach enforce PEP 8 naming conventions and documentation standards?

Yes, this approach enforces PEP 8 naming conventions for variables, functions, classes, and constants. It also implements Google-style docstrings for all public APIs to improve code understanding and maintainability.

Why do I need static analysis tools like mypy for maintaining a Python codebase?

You need static analysis tools like mypy to catch potential bugs and type errors early in the development cycle. Combined with ruff for linting, these tools address the need for maintainable and collaborative Python codebases.

Can I use ruff to catch style violations and potential bugs in a new Python project?

Yes, you can use ruff to catch style violations and potential bugs when starting a new Python project. Configuring ruff in pyproject.toml ensures all code adheres to established style standards from the beginning.