Skip to main content
Scaffolds a repository class and its test file into the target module. It writes modules/<module>/src/repositories/<Name>Repository.ts and modules/<module>/tests/repositories/<Name>Repository.spec.ts, and installs the @talosjs/repository dependency if it is missing.

Usage

talos repository:create [options]

Examples

talos repository:create
talos repository:create --name=Product
talos repository:create --name=UserRepository --module=auth --override

Options

OptionDescriptionDefault
--nameResource name (the Repository suffix is appended automatically).Prompted if omitted
--moduleTarget module.shared
--overrideOverwrite an existing file without confirmation.false

AI Skill

This command ships a matching repository:create skill. Your AI agent uses it to generate a new TypeORM repository class and its test file, then complete the CRUD and domain-specific methods for database operations on an entity.
talos claude:init