- Home
- Skills
- Codyswanngt
- Lisa
- Ops Db Ops
ops-db-ops_skill
- TypeScript
1
GitHub Stars
1
Bundled Files
2 months ago
Catalog Refreshed
4 months ago
First Indexed
Readme & install
Copy the install command, review bundled files from the catalogue, and read any extended description pulled from the listing source.
Installation
Preview and clipboard use veilstrat where the catalogue uses aiagentskills.
npx veilstrat add skill codyswanngt/lisa --skill ops-db-ops- SKILL.md3.1 KB
Overview
This skill automates database migrations, reverts, schema generation, and GraphQL code generation for Expo + serverless backends using TypeORM. It operates across the backend (migrations, SQL schema) and frontend (GraphQL type generation), streamlining common devops tasks. It enforces a safety guardrail: never run destructive operations against production without explicit human confirmation.
How this skill works
The skill discovers runnable scripts by reading package.json files in the backend and frontend projects and maps high-level commands (migrate, revert, generate, schema, codegen) to concrete bun run scripts. For database operations it ensures AWS credentials are present by invoking the backend aws signin script before running TypeORM migration or schema commands. For frontend codegen it fetches the GraphQL schema from the running backend and then runs type generation scripts.
When to use it
- Apply pending database migrations on a local or remote environment.
- Revert the last applied migration when a change needs to be undone.
- Generate a new migration after changing TypeORM entities.
- Regenerate the canonical SQL schema used by MCP workflows.
- Regenerate frontend GraphQL TypeScript types after schema changes.
Best practices
- Always run the backend aws signin step before any migration or schema operation that accesses remote databases.
- Never run migrate or revert against production without explicit human confirmation and a backup.
- Run codegen only after the backend is running (locally or deployed) so schema fetching succeeds.
- Set BACKEND_DIR in local settings if your backend is not at the default relative path.
- Name generated migrations clearly (NAME={migration_name}) to track intent in version control.
Example use cases
- Apply two pending migrations to your dev database: STAGE=dev migration:run:local.
- Undo a faulty migration on a staging instance after human review: STAGE=staging migration:revert:remote:local.
- Create a new migration from entity changes: NAME=add-user-index migration:generate:dev.
- Regenerate the SQL schema artifact used by MCP: STAGE=prod generate:sql-schema.
- Refresh frontend TypeScript types after schema updates: fetch schema then generate types for the chosen environment.
FAQ
No. AWS credentials are required for database operations but not for frontend codegen. Codegen requires the backend to be reachable so schema fetching succeeds.
How do I target a non-default backend directory?
Set BACKEND_DIR in your local settings to point to your backend path, then commands will operate there instead of the default ../backend-v2.