diff --git a/self-host/clickhouse/20231117020810_create-events-table.sql b/self-host/clickhouse/20231117020810_create_events_table.sql similarity index 100% rename from self-host/clickhouse/20231117020810_create-events-table.sql rename to self-host/clickhouse/20231117020810_create_events_table.sql diff --git a/self-host/postgres/20231117010312_create-teams-relation.sql b/self-host/postgres/20231117010312_create_teams_table.sql similarity index 100% rename from self-host/postgres/20231117010312_create-teams-relation.sql rename to self-host/postgres/20231117010312_create_teams_table.sql diff --git a/self-host/postgres/20231117010526_create-apps-relation.sql b/self-host/postgres/20231117010526_create_apps_table.sql similarity index 100% rename from self-host/postgres/20231117010526_create-apps-relation.sql rename to self-host/postgres/20231117010526_create_apps_table.sql diff --git a/self-host/postgres/20231117011737_create-roles-relation.sql b/self-host/postgres/20231117011737_create_roles_table.sql similarity index 100% rename from self-host/postgres/20231117011737_create-roles-relation.sql rename to self-host/postgres/20231117011737_create_roles_table.sql diff --git a/self-host/postgres/20231117012011_create-build_mappings-relation.sql b/self-host/postgres/20231117012011_create_build_mappings_table.sql similarity index 100% rename from self-host/postgres/20231117012011_create-build_mappings-relation.sql rename to self-host/postgres/20231117012011_create_build_mappings_table.sql diff --git a/self-host/postgres/20231117012219_create-team_membership-relation.sql b/self-host/postgres/20231117012219_create_team_membership_table.sql similarity index 100% rename from self-host/postgres/20231117012219_create-team_membership-relation.sql rename to self-host/postgres/20231117012219_create_team_membership_table.sql diff --git a/self-host/postgres/20231122211412_create-api_keys-relation.sql b/self-host/postgres/20231122211412_create_api_keys_table.sql similarity index 100% rename from self-host/postgres/20231122211412_create-api_keys-relation.sql rename to self-host/postgres/20231122211412_create_api_keys_table.sql diff --git a/self-host/postgres/20231228033348_create-unhandled_exception_groups-relation.sql b/self-host/postgres/20231228033348_create_unhandled_exception_groups_table.sql similarity index 100% rename from self-host/postgres/20231228033348_create-unhandled_exception_groups-relation.sql rename to self-host/postgres/20231228033348_create_unhandled_exception_groups_table.sql diff --git a/self-host/postgres/20231228044339_create-anr_groups-relation.sql b/self-host/postgres/20231228044339_create_anr_groups_table.sql similarity index 100% rename from self-host/postgres/20231228044339_create-anr_groups-relation.sql rename to self-host/postgres/20231228044339_create_anr_groups_table.sql diff --git a/self-host/postgres/20240311054505_create-build_sizes-relation.sql b/self-host/postgres/20240311054505_create_build_sizes_table.sql similarity index 100% rename from self-host/postgres/20240311054505_create-build_sizes-relation.sql rename to self-host/postgres/20240311054505_create_build_sizes_table.sql diff --git a/self-host/postgres/20240502060117_create-event_reqs-schema.sql b/self-host/postgres/20240502060117_create_event_reqs_table.sql similarity index 100% rename from self-host/postgres/20240502060117_create-event_reqs-schema.sql rename to self-host/postgres/20240502060117_create_event_reqs_table.sql diff --git a/self-host/postgres/20240703152041_create-auth_states-relation.sql b/self-host/postgres/20240703152041_create_auth_states_table.sql similarity index 100% rename from self-host/postgres/20240703152041_create-auth_states-relation.sql rename to self-host/postgres/20240703152041_create_auth_states_table.sql diff --git a/self-host/postgres/20240704051355_create-auth_sessions-relation.sql b/self-host/postgres/20240704051355_create_auth_sessions_table.sql similarity index 100% rename from self-host/postgres/20240704051355_create-auth_sessions-relation.sql rename to self-host/postgres/20240704051355_create_auth_sessions_table.sql diff --git a/self-host/postgres/README.md b/self-host/postgres/README.md index 2406df1c5..ab28dce9b 100644 --- a/self-host/postgres/README.md +++ b/self-host/postgres/README.md @@ -13,16 +13,16 @@ Schema migrations for postgres instances are managed using [dbmate](https://gith - Migrations **MUST** contain both `up` & `down` migrations - **NEVER** edit the generated `schema.sql` file manually - Follow this naming convention for naming migration files - - Syntax: `--` + - Syntax: `__` - `` should be `create` or `alter` etc sql commands - `` should be name of the relation or role or function or trigger etc - - `` should be name of the sql entity type, like `relation`(or `table`), `function`, `role`, `index`, `trigger` + - `` should be name of the sql entity type, like `table`, `function`, `role`, `index`, `trigger` - Examples: - - `dbmate new create-sessions-relation` - - `dbmate new create-sessions_attachments-relation` - - `dbmate new create-create_team-function` - - `dbmate new create-create_team_for_user-trigger` - - `dbmate new alter-teams-relation` - add a new column + - `dbmate new create_sessions_table` + - `dbmate new create_sessions_attachments_table` + - `dbmate new create_create_team_function` + - `dbmate new create_create_team_for_user_trigger` + - `dbmate new alter_teams_relation` - add a new column - When authoring migrations, always prefix the schema name in your objects ## Deleting old migrations