mirror of
https://github.com/affaan-m/everything-claude-code.git
synced 2026-06-11 10:43:10 +08:00
docs: add Spanish (es) translation (#2095)
Adds a complete Spanish translation of the ECC documentation under docs/es/, mirroring the Turkish (docs/tr/) translation in scope. 141 files covering agents, commands, rules, skills, contexts, examples, and core docs. Updates root README.md with the Spanish language link. Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
committed by
GitHub
parent
28b78dd7bf
commit
ac0f11c640
42
docs/es/rules/python/coding-style.md
Normal file
42
docs/es/rules/python/coding-style.md
Normal file
@@ -0,0 +1,42 @@
|
||||
---
|
||||
paths:
|
||||
- "**/*.py"
|
||||
- "**/*.pyi"
|
||||
---
|
||||
# Estilo de Código en Python
|
||||
|
||||
> Este archivo extiende [common/coding-style.md](../common/coding-style.md) con contenido específico de Python.
|
||||
|
||||
## Estándares
|
||||
|
||||
- Seguir las convenciones de **PEP 8**
|
||||
- Usar **anotaciones de tipos** en todas las firmas de funciones
|
||||
|
||||
## Inmutabilidad
|
||||
|
||||
Preferir estructuras de datos inmutables:
|
||||
|
||||
```python
|
||||
from dataclasses import dataclass
|
||||
|
||||
@dataclass(frozen=True)
|
||||
class User:
|
||||
name: str
|
||||
email: str
|
||||
|
||||
from typing import NamedTuple
|
||||
|
||||
class Point(NamedTuple):
|
||||
x: float
|
||||
y: float
|
||||
```
|
||||
|
||||
## Formateo
|
||||
|
||||
- **black** para formateo de código
|
||||
- **isort** para ordenamiento de imports
|
||||
- **ruff** para linting
|
||||
|
||||
## Referencia
|
||||
|
||||
Ver skill: `python-patterns` para idiomas y patrones completos de Python.
|
||||
19
docs/es/rules/python/hooks.md
Normal file
19
docs/es/rules/python/hooks.md
Normal file
@@ -0,0 +1,19 @@
|
||||
---
|
||||
paths:
|
||||
- "**/*.py"
|
||||
- "**/*.pyi"
|
||||
---
|
||||
# Hooks de Python
|
||||
|
||||
> Este archivo extiende [common/hooks.md](../common/hooks.md) con contenido específico de Python.
|
||||
|
||||
## Hooks PostToolUse
|
||||
|
||||
Configurar en `~/.claude/settings.json`:
|
||||
|
||||
- **black/ruff**: Auto-formatear archivos `.py` después de editar
|
||||
- **mypy/pyright**: Ejecutar verificación de tipos después de editar archivos `.py`
|
||||
|
||||
## Advertencias
|
||||
|
||||
- Advertir sobre sentencias `print()` en los archivos editados (usar el módulo `logging` en su lugar)
|
||||
39
docs/es/rules/python/patterns.md
Normal file
39
docs/es/rules/python/patterns.md
Normal file
@@ -0,0 +1,39 @@
|
||||
---
|
||||
paths:
|
||||
- "**/*.py"
|
||||
- "**/*.pyi"
|
||||
---
|
||||
# Patrones de Python
|
||||
|
||||
> Este archivo extiende [common/patterns.md](../common/patterns.md) con contenido específico de Python.
|
||||
|
||||
## Protocol (Duck Typing)
|
||||
|
||||
```python
|
||||
from typing import Protocol
|
||||
|
||||
class Repository(Protocol):
|
||||
def find_by_id(self, id: str) -> dict | None: ...
|
||||
def save(self, entity: dict) -> dict: ...
|
||||
```
|
||||
|
||||
## Dataclasses como DTOs
|
||||
|
||||
```python
|
||||
from dataclasses import dataclass
|
||||
|
||||
@dataclass
|
||||
class CreateUserRequest:
|
||||
name: str
|
||||
email: str
|
||||
age: int | None = None
|
||||
```
|
||||
|
||||
## Context Managers y Generadores
|
||||
|
||||
- Usar context managers (sentencia `with`) para gestión de recursos
|
||||
- Usar generadores para evaluación lazy e iteración eficiente en memoria
|
||||
|
||||
## Referencia
|
||||
|
||||
Ver skill: `python-patterns` para patrones completos incluyendo decoradores, concurrencia y organización de paquetes.
|
||||
30
docs/es/rules/python/security.md
Normal file
30
docs/es/rules/python/security.md
Normal file
@@ -0,0 +1,30 @@
|
||||
---
|
||||
paths:
|
||||
- "**/*.py"
|
||||
- "**/*.pyi"
|
||||
---
|
||||
# Seguridad en Python
|
||||
|
||||
> Este archivo extiende [common/security.md](../common/security.md) con contenido específico de Python.
|
||||
|
||||
## Gestión de Secretos
|
||||
|
||||
```python
|
||||
import os
|
||||
from dotenv import load_dotenv
|
||||
|
||||
load_dotenv()
|
||||
|
||||
api_key = os.environ["OPENAI_API_KEY"] # Lanza KeyError si falta
|
||||
```
|
||||
|
||||
## Escaneo de Seguridad
|
||||
|
||||
- Usar **bandit** para análisis estático de seguridad:
|
||||
```bash
|
||||
bandit -r src/
|
||||
```
|
||||
|
||||
## Referencia
|
||||
|
||||
Ver skill: `django-security` para directrices de seguridad específicas de Django (si aplica).
|
||||
38
docs/es/rules/python/testing.md
Normal file
38
docs/es/rules/python/testing.md
Normal file
@@ -0,0 +1,38 @@
|
||||
---
|
||||
paths:
|
||||
- "**/*.py"
|
||||
- "**/*.pyi"
|
||||
---
|
||||
# Pruebas en Python
|
||||
|
||||
> Este archivo extiende [common/testing.md](../common/testing.md) con contenido específico de Python.
|
||||
|
||||
## Framework
|
||||
|
||||
Usar **pytest** como framework de pruebas.
|
||||
|
||||
## Cobertura
|
||||
|
||||
```bash
|
||||
pytest --cov=src --cov-report=term-missing
|
||||
```
|
||||
|
||||
## Organización de Pruebas
|
||||
|
||||
Usar `pytest.mark` para categorización de pruebas:
|
||||
|
||||
```python
|
||||
import pytest
|
||||
|
||||
@pytest.mark.unit
|
||||
def test_calculate_total():
|
||||
...
|
||||
|
||||
@pytest.mark.integration
|
||||
def test_database_connection():
|
||||
...
|
||||
```
|
||||
|
||||
## Referencia
|
||||
|
||||
Ver skill: `python-testing` para patrones detallados de pytest y fixtures.
|
||||
Reference in New Issue
Block a user