Skip to content

Releases: myxiaoao/database-structure-sync

v1.4.0

Choose a tag to compare

@github-actions github-actions released this 03 Apr 08:57

What's Changed

Cross-Database Type Synchronization

MySQL, PostgreSQL, and MariaDB schemas can now be compared and synchronized in all directions. This is powered by a canonical intermediate type system that maps between database-specific types.

Core features:

  • CanonicalType — database-agnostic intermediate type enum covering 30+ type variants
  • Type Mappers — MySQL, PostgreSQL, and MariaDB each have independent mappers with to_canonical / from_canonical / map_default_value
  • MariaDB independence — native uuid, inet6 support, jsonb → longtext (not reusing MySQL mapper)
  • Type warnings — inline icons on diff tree items + summary panel showing degraded/skipped conversions
  • Default value normalization — now() ↔ CURRENT_TIMESTAMP, true/false ↔ 1/0, PG cast stripping

PostgreSQL Improvements

  • Array type support — reads array columns via udt_name (e.g., _int4 → integer[])
  • Enum support — reads enum values from pg_enum, generates CREATE TYPE AS ENUM when targeting PostgreSQL
  • Serial variants — SERIAL/BIGSERIAL/SMALLSERIAL chosen based on integer width
  • ALTER COLUMN auto_increment — generates CREATE SEQUENCE + SET DEFAULT nextval() + OWNED BY

Bug Fixes

  • Frontend DiffType aligned with backend snake_case serialization — fixes diff item color/icon/badge rendering
  • Skipped (unmappable) columns now produce visible DiffItems with warnings instead of being silently dropped
  • CREATE TABLE in cross-db mode filters skipped columns from PK, indexes, FKs, and unique constraints
  • Indexes/FKs/UCs referencing skipped columns are excluded from cross-db comparison

Full Changelog: v1.3.0...v1.4.0

v1.3.0

Choose a tag to compare

@github-actions github-actions released this 27 Mar 07:10

What's Changed

New Features

  • Timestamped SQL export filenames — exported SQL files now default to sync_YYYYMMDDHHmmss.sql to prevent accidentally overwriting previous exports

UI Improvements

  • Redesigned main layout for clearer information hierarchy
  • Redesigned endpoint selector as unified card with compact horizontal toolbar layout
  • Unified horizontal padding (px-5) across header and content
  • Unified border-radius and overflow handling across components
  • Polished diff tree readability, SQL preview panel, toolbar, and bottom bar
  • Fine-tuned compare button contrast, height alignment, and toolbar font size
  • Softened compare button style and improved SQL empty state
  • Eliminated flash on re-compare by keeping old results visible

Bug Fixes

  • Skip keychain reads in list_connections to prevent errors

Docs

  • Added macOS Gatekeeper workaround instructions

Full Changelog: v1.2.0...v1.3.0

v1.2.0

Choose a tag to compare

@myxiaoao myxiaoao released this 26 Mar 08:45

What's Changed

Bug Fixes

  • Fix edit-connection creating duplicates — editing a connection now calls update_connection instead of always inserting a new record

Security

  • SSH known_hosts verification — implement TOFU (Trust On First Use) host key checking against ~/.ssh/known_hosts, reject connections on key mismatch (MITM protection)
  • SSL verify_server enforcement — verify_server flag now correctly switches between VerifyCa and Required/Require SSL modes for MySQL and PostgreSQL

Performance

  • Batch metadata queries — get_tables reduced from 5N+1 to 6 fixed queries per schema read

Refactoring

  • Split ConnectionForm into sub-components (formMapper, useConnectionForm, BasicTab/SshTab/SslTab)
  • Split main.rs into commands.rs + driver.rs modules
  • Split mysql.rs and postgres.rs into reader/generator sub-modules
  • Extract generic compare_named_items for diff comparator
  • Extract SqlGenerator delegation macro
  • Extract shared validate_fk_action
  • Extract load_connection / create_driver command helpers
  • Extract SQL header/footer generation to src/lib/sql/
  • Extract ConnectionSelector component from SyncPage
  • Split config.rs unit tests to config_tests.rs

Maintenance

  • Sync APP_VERSION with package.json via Vite define
  • i18n for all toast messages in mutations
  • Fix isSaving to include both save and update mutation states
  • Remove duplicate #[test] attribute
  • Add staleTime/gcTime to database list query cache
  • Add DialogDescription for a11y compliance
  • Remove empty react-vendor build chunk

Database Structure Sync v1.1.0

Choose a tag to compare

@github-actions github-actions released this 24 Feb 03:21

What's Changed

Added

  • Cross-database type warning when comparing incompatible databases (e.g. MySQL vs PostgreSQL)
  • Connection form validation for required fields (name, host, port, username)
  • Detailed column diff display showing full definition differences

Fixed

  • Error toast showing "undefined" instead of actual error message from Tauri backend
  • Duplicate key error caused by UNIQUE constraints being listed as both indexes and constraints
  • MODIFY COLUMN on nullable timestamp columns silently failing due to missing explicit NULL DEFAULT NULL
  • False positive column diffs caused by ordinal_position comparison
  • Missing blank line between SQL body and footer in exported SQL files
  • Accidental connection creation triggered by pressing Enter in form input fields
  • Empty connections being saved when required fields are blank

Changed

  • Default window size increased from 1200×800 to 1400×900
  • Minimum window size increased from 900×600 to 1200×800

Full Changelog: v1.0.0...v1.1.0

v1.0.0

Choose a tag to compare

@myxiaoao myxiaoao released this 23 Feb 00:50

🎉 First Stable Release

Cross-platform database schema comparison and synchronization tool built with Tauri 2.x + React 19.

Features

  • Database Support: MySQL, PostgreSQL, and MariaDB
  • Schema Comparison: Diff visualization with detailed change tracking
  • SQL Generation: Migration script generation and export
  • Connection Management: Secure password storage via system keychain
  • SSH Tunnel: Support for remote database connections
  • SSL/TLS: Encryption support for secure connections
  • i18n: English and Chinese language support
  • Themes: Dark / Light / System theme support
  • Cross-platform: Windows, macOS, and Linux

Security

  • Content Security Policy (CSP) configuration
  • Capabilities-based permission model
  • Secure credential storage using system keychain