mirror of
https://github.com/simplex-chat/simplex-chat.git
synced 2026-10-23 06:22:43 +00:00
redate migration
This commit is contained in:
1 parent
29f612225a
commit
58916c0303
5 files changed
+16
-16
No files matched your search
+2
-2
@@ -161,7 +161,7 @@ library
|
||||
Simplex.Chat.Store.Postgres.Migrations.M20260720_server_roles
|
||||
Simplex.Chat.Store.Postgres.Migrations.M20260723_contact_request_rejection
|
||||
Simplex.Chat.Store.Postgres.Migrations.M20260731_user_badges
|
||||
Simplex.Chat.Store.Postgres.Migrations.M20260806_wallet_seeds
|
||||
Simplex.Chat.Store.Postgres.Migrations.M20260818_wallet_seeds
|
||||
else
|
||||
exposed-modules:
|
||||
Simplex.Chat.Archive
|
||||
@@ -333,7 +333,7 @@ library
|
||||
Simplex.Chat.Store.SQLite.Migrations.M20260720_server_roles
|
||||
Simplex.Chat.Store.SQLite.Migrations.M20260723_contact_request_rejection
|
||||
Simplex.Chat.Store.SQLite.Migrations.M20260731_user_badges
|
||||
Simplex.Chat.Store.SQLite.Migrations.M20260806_wallet_seeds
|
||||
Simplex.Chat.Store.SQLite.Migrations.M20260818_wallet_seeds
|
||||
other-modules:
|
||||
Paths_simplex_chat
|
||||
hs-source-dirs:
|
||||
|
||||
@@ -46,7 +46,7 @@ import Simplex.Chat.Store.Postgres.Migrations.M20260715_profile_description
|
||||
import Simplex.Chat.Store.Postgres.Migrations.M20260716_signed_history
|
||||
import Simplex.Chat.Store.Postgres.Migrations.M20260720_server_roles
|
||||
import Simplex.Chat.Store.Postgres.Migrations.M20260723_contact_request_rejection
|
||||
import Simplex.Chat.Store.Postgres.Migrations.M20260806_wallet_seeds
|
||||
import Simplex.Chat.Store.Postgres.Migrations.M20260818_wallet_seeds
|
||||
import Simplex.Messaging.Agent.Store.Shared (Migration (..))
|
||||
|
||||
schemaMigrations :: [(String, Text, Maybe Text)]
|
||||
@@ -93,7 +93,7 @@ schemaMigrations =
|
||||
("20260716_signed_history", m20260716_signed_history, Just down_m20260716_signed_history),
|
||||
("20260720_server_roles", m20260720_server_roles, Just down_m20260720_server_roles),
|
||||
("20260723_contact_request_rejection", m20260723_contact_request_rejection, Just down_m20260723_contact_request_rejection),
|
||||
("20260806_wallet_seeds", m20260806_wallet_seeds, Just down_m20260806_wallet_seeds)
|
||||
("20260818_wallet_seeds", m20260818_wallet_seeds, Just down_m20260818_wallet_seeds)
|
||||
]
|
||||
|
||||
-- | The list of migrations in ascending order by date
|
||||
|
||||
+5
-5
@@ -1,13 +1,13 @@
|
||||
{-# LANGUAGE OverloadedStrings #-}
|
||||
{-# LANGUAGE QuasiQuotes #-}
|
||||
|
||||
module Simplex.Chat.Store.Postgres.Migrations.M20260806_wallet_seeds where
|
||||
module Simplex.Chat.Store.Postgres.Migrations.M20260818_wallet_seeds where
|
||||
|
||||
import Data.Text (Text)
|
||||
import Text.RawString.QQ (r)
|
||||
|
||||
m20260806_wallet_seeds :: Text
|
||||
m20260806_wallet_seeds =
|
||||
m20260818_wallet_seeds :: Text
|
||||
m20260818_wallet_seeds =
|
||||
[r|
|
||||
CREATE TABLE wallet_seeds (
|
||||
wallet_seed_id BIGINT GENERATED ALWAYS AS IDENTITY PRIMARY KEY,
|
||||
@@ -23,8 +23,8 @@ ALTER TABLE users ADD COLUMN wallet_account_index BIGINT;
|
||||
CREATE INDEX idx_users_wallet_seed_id ON users(wallet_seed_id);
|
||||
|]
|
||||
|
||||
down_m20260806_wallet_seeds :: Text
|
||||
down_m20260806_wallet_seeds =
|
||||
down_m20260818_wallet_seeds :: Text
|
||||
down_m20260818_wallet_seeds =
|
||||
[r|
|
||||
DROP INDEX idx_users_wallet_seed_id;
|
||||
|
||||
@@ -169,7 +169,7 @@ import Simplex.Chat.Store.SQLite.Migrations.M20260715_profile_description
|
||||
import Simplex.Chat.Store.SQLite.Migrations.M20260716_signed_history
|
||||
import Simplex.Chat.Store.SQLite.Migrations.M20260720_server_roles
|
||||
import Simplex.Chat.Store.SQLite.Migrations.M20260723_contact_request_rejection
|
||||
import Simplex.Chat.Store.SQLite.Migrations.M20260806_wallet_seeds
|
||||
import Simplex.Chat.Store.SQLite.Migrations.M20260818_wallet_seeds
|
||||
import Simplex.Messaging.Agent.Store.Shared (Migration (..))
|
||||
|
||||
schemaMigrations :: [(String, Query, Maybe Query)]
|
||||
@@ -326,7 +326,7 @@ schemaMigrations =
|
||||
("20260514_relay_request_group_link_index", m20260514_relay_request_group_link_index, Just down_m20260514_relay_request_group_link_index),
|
||||
("20260515_public_group_access", m20260515_public_group_access, Just down_m20260515_public_group_access),
|
||||
("20260516_supporter_badges", m20260516_supporter_badges, Just down_m20260516_supporter_badges),
|
||||
("20260806_wallet_seeds", m20260806_wallet_seeds, Just down_m20260806_wallet_seeds),
|
||||
("20260818_wallet_seeds", m20260818_wallet_seeds, Just down_m20260818_wallet_seeds),
|
||||
("20260529_delivery_job_senders", m20260529_delivery_job_senders, Just down_m20260529_delivery_job_senders),
|
||||
("20260530_client_services", m20260530_client_services, Just down_m20260530_client_services),
|
||||
("20260531_member_removed_at", m20260531_member_removed_at, Just down_m20260531_member_removed_at),
|
||||
|
||||
+5
-5
@@ -1,6 +1,6 @@
|
||||
{-# LANGUAGE QuasiQuotes #-}
|
||||
|
||||
module Simplex.Chat.Store.SQLite.Migrations.M20260806_wallet_seeds where
|
||||
module Simplex.Chat.Store.SQLite.Migrations.M20260818_wallet_seeds where
|
||||
|
||||
import Database.SQLite.Simple (Query)
|
||||
import Database.SQLite.Simple.QQ (sql)
|
||||
@@ -10,8 +10,8 @@ import Database.SQLite.Simple.QQ (sql)
|
||||
-- The schema allows several seeds, with each chat profile bound to exactly one
|
||||
-- of them plus its own BIP-44 account index. Only the single-seed case is
|
||||
-- reachable today.
|
||||
m20260806_wallet_seeds :: Query
|
||||
m20260806_wallet_seeds =
|
||||
m20260818_wallet_seeds :: Query
|
||||
m20260818_wallet_seeds =
|
||||
[sql|
|
||||
CREATE TABLE wallet_seeds (
|
||||
wallet_seed_id INTEGER PRIMARY KEY AUTOINCREMENT,
|
||||
@@ -30,8 +30,8 @@ ALTER TABLE users ADD COLUMN wallet_account_index INTEGER;
|
||||
CREATE INDEX idx_users_wallet_seed_id ON users(wallet_seed_id);
|
||||
|]
|
||||
|
||||
down_m20260806_wallet_seeds :: Query
|
||||
down_m20260806_wallet_seeds =
|
||||
down_m20260818_wallet_seeds :: Query
|
||||
down_m20260818_wallet_seeds =
|
||||
[sql|
|
||||
DROP INDEX idx_users_wallet_seed_id;
|
||||
|
||||
Reference in new issue
Block a user