Commandscc db
cc db rename
Rename a database — both the PostgreSQL database and cc's record.
Usage
cc db rename <old> <new>Arguments
| Argument | Description |
|---|---|
old | Current database name (tab-completable) |
new | New database name |
What it does
- Renames the PostgreSQL database (direct connection or via
docker exec, so it works on a dockerized Postgres) and updates cc's cache record. - If the renamed database is the active environment's database, rewrites
cc.databasein the version'ssettings.jsonto the new name.
Related
cc db— database group overviewcc db use— set the active databasecc db drop— drop a database