Welcome to the Coastline documentation! Coastline is a Python package for declarative configuration management using Pydantic types and YAML config files.
Coastline provides a simple, type-safe way to manage application configuration:
@config decoratorfrom coastline import config, ConfigLoader
from pydantic import BaseModel
@config
class Database(BaseModel):
host: str
port: int
name: str
# config.yaml:
# Database:
# host: localhost
# port: 5432
# name: myapp
loader = ConfigLoader()
cfg = loader.load("config.yaml")
print(cfg["Database"].host) # "localhost"
Coastline is released under the MIT License.