v0.1.0

Changelog

Generated from CHANGELOG.md in the project repository. Never maintained twice.

Unreleased

  • addedCLI: coloured, grouped output for lint/validate, plan and migration views via runemark; --color auto|always|never controls it, NO_COLOR is honoured, and --json, --format json|sarif and generated artifacts never contain colour codes.
  • addedCLI: databee init creates a project, databee inspect summarizes it and reports diagnostics, and --json prints a single machine-readable object for every command.
  • addedCLI: databee pull reads a PostgreSQL 15–19 database into the project. Repeated pulls keep model IDs, including for tables and columns renamed in the database. Sequences owned by a column (serial, bigserial, smallserial, OWNED BY) are read into the column; all other sequences are reported as DB-INT-001.
  • addedCLI: databee connection list and databee connection test use local connection profiles that stay outside the project and never show passwords.
  • addedCLI: databee generate ddl writes PostgreSQL DDL from the project without a running database, including CREATE SEQUENCE and OWNED BY for sequences owned by a column.
  • addedCLI: databee validate checks project files and the model structure, and --fix applies safe corrections.
  • addedCLI: databee lint checks PostgreSQL best practices with configurable severities and suppressions that need a reason. --fix applies safe corrections, and --format sarif produces output for CI. PG016 warns about a default that calls nextval of a sequence the model does not know.
  • addedCLI: databee lint reports PG017 as an error for PostgreSQL identifiers longer than 63 bytes (or equal to another after truncation), which PostgreSQL would silently shorten.
  • addedCLI: databee visualize erd draws the model as a Mermaid or Graphviz DOT entity relationship diagram, with keys and cardinalities, and uses positions from diagrams/layout.json for DOT.
  • addedCLI: databee generate dbml writes the model as DBML, and databee import dbml reads a DBML file into an empty project and reports unsupported constructs with their line.
  • addedCLI: databee snapshot stores the current model as an immutable snapshot that later diffs and ALTER plans start from.
  • addedCLI: databee generate alter plans the PostgreSQL changes between two model stages as plans/<name>.json and .sql, using lock-friendly steps (concurrent indexes, NOT VALID plus VALIDATE) and flagging destructive, rewriting and backfill steps.
  • addedCLI: databee plan show lists the steps, risks and hash of a plan, and databee plan approve records a human approval for that exact plan hash outside the project; it needs a terminal and has no --yes flag.
  • addedCLI: databee plan apply runs an approved plan against a database after checking that the database still matches the plan's source model, continues an interrupted run after the last completed step, and compares the database with the target model at the end.
  • addedCLI: databee visualize render draws the model as a deterministic SVG or HTML diagram (views erd, focus, diff, overview; light, dark and print themes). --view diff marks the changes since a snapshot, and --open opens the file only in an interactive terminal.
  • addedMCP: databee mcp serve --transport stdio --project <path> starts a Model Context Protocol server with the tools schema_summary, schema_validate, schema_visualize and schema_diff. They never change the model; schema_visualize with output: true writes only below diagrams/ of the project and rejects any other location. skills/databee/SKILL.md tells agents when to use which tool.
  • addedProject format: the model is stored as one JSON file per entity with stable IDs, and every file references a JSON Schema for editors and agents.
  • addedCLI: databee changeset apply <file|-> applies a JSON changeset (operations such as add_entity, add_foreign_key and rename_field, with ref labels for new objects) to the model as a whole or not at all. It checks the model revision, validates, writes atomically, and leaves every file unchanged if it rejects the changeset. --dry-run writes nothing.
  • addedCLI: databee undo takes the last changeset back, databee revision prints the model revision, and databee changeset schema prints the JSON Schema of changesets.
  • addedMCP: databee mcp serve --profile <name> (repeatable) adds tools to the default reader profile: designer (schema_apply_changeset, schema_undo, schema_add_entity, schema_add_field, schema_add_foreign_key), generator (generate_ddl, generate_dbml, generate_code), planner (schema_snapshot, plan_generate_alter, plan_show) and operator (plan_apply). No profile can approve a plan, and plan_apply runs only a plan whose current hash a human approved.
  • addedMCP: schema_get returns the model with IDs and its revision as structured JSON, and every reply that carries model or database text is marked "content_origin": "data".
  • addedProject format: changesets keep an undo history in .databee/history/, and databee init adds .databee/ to the project's .gitignore. Diagnostics DB-CHG-001 to DB-CHG-004 report rejected changesets and undo refusals.
  • addedCLI: databee undo --dry-run reports whether undo is possible and which changeset it would take back, and writes nothing.
  • addedMCP: schema_undo accepts dry_run to report whether undo is possible without changing the model.
  • addedCLI: databee generate code --lang rust|typescript|python|csharp writes sqlx structs, a Drizzle schema, SQLAlchemy 2.0 models or EF Core entities with a DbContext to generated/<lang>/ (or --output <dir>). What a library cannot carry is reported as DB-GEN-001 to DB-GEN-007 on the model object.
  • addedCLI: databee studio [path] opens a project in the installed databee studio app: databee-studio on PATH, else databee Studio.app in /Applications or ~/Applications. Without the app it says so and exits.
  • addedStudio: databee studio, a Tauri desktop app in studio/, opens a project and shows its entity relationship diagram with columns, keys, foreign key edges and finding counts per entity. Positions come from diagrams/layout.json or an automatic layout, dragging an entity saves its position, and a banner offers a reload when the project changed on disk. Editing follows later.
  • addedStudio: pnpm dev:mock in studio/ui runs the interface in a normal browser against a fixture project, without Tauri.
  • addedStudio: the diagram shows PostgreSQL types as the renderer spells them (bigint, numeric(10,2), varchar(254)), crow's foot cardinality markers on foreign key edges that attach at the key columns on the facing sides of the boxes, and edges that stay visible in dark mode.
  • addedStudio: entities, columns, primary and unique keys, indexes, foreign keys (also over several columns), enum types (create, change values), check constraints and namespaces (chosen when creating an entity) are edited in the side panel. Dragging from a column handle onto a column of another entity creates a foreign key with ON DELETE and ON UPDATE choices. Every edit is a changeset checked with a dry run first; Delete drops the selection after a confirmation that names the foreign keys of other entities dropped with it, and Undo takes back the last step.
  • addedStudio: foreign key edges use the same router as the SVG renderer (orthogonal, own lanes, around boxes), compiled to WebAssembly and rerouted while you drag; building the studio needs wasm-pack. The packaged app loads the router too, so foreign key lines are routed around entities instead of crossing them.
  • addedStudio: the diagram works from the keyboard: entities and foreign keys show a focus ring and have readable names, and Enter or Space opens the focused one in the side panel.
  • addedStudio: findings show at the entity, at the column and in a side panel list, with an Apply fix button where a fix exists. An edit rejected because the project changed meanwhile shows a conflict notice, reloads and is not retried.
  • addedStudio: a DDL view with a copy button, snapshots with a name, an ALTER preview from a chosen snapshot with lock, rewrite and destructive flags, and an approval dialog that shows steps, risks and hash and asks for the plan name before a destructive plan is approved.
  • addedMCP: generate_code in the generator profile returns the generated files inline, or with output: true writes them below generated/ of the project only.
  • addedCLI: databee export <profile> runs an export profile exports/<name>.toml: row data as csv, ndjson, sql-insert or sql-copy, streamed from one consistent read-only transaction, plus schema artifacts (ddl, dbml, json-schema, dictionary, diagram). Two runs on unchanged data write identical files and manifest.json. databee export list and databee export check <profile> list and validate profiles.
  • addedCLI: exports report DB-EXP-001 to DB-EXP-008 (reserved masking and subset fields, table without a primary key, details a JSON Schema cannot carry, invalid profile with file and JSON path, unmatched entity pattern, skipped entity, duplicate output, foreign key cycle). SQL exports are ordered parents first (load_order in manifest.json) and end with setval for identity and owned sequences.
  • addedMCP: the exporter profile (--profile exporter) adds export_list, export_check, export_profile_save and export_run. Profiles are saved only below exports/, validated first; export_run writes only below out/ of the project and rejects links out of it.
  • addedProject format: export profiles live in exports/<name>.toml without credentials, with a JSON Schema in .databee/schemas/export.schema.json. databee init adds out/ to the project's .gitignore, because data exports can hold personal data.
  • addedCLI: databee pull reads MySQL 8.4 and 9.x, MariaDB 10.11 and 11.4 (mysql://, mariadb://) and SQLite (sqlite:path) databases and takes the dialect from the URL scheme. Tables, columns with their native properties (UNSIGNED, AUTO_INCREMENT, generated columns, ENUM, SET, affinity, STRICT, WITHOUT ROWID), keys, checks, indexes, comments, engine and collations are captured; everything else is reported as DB-INT-001.
  • addedCLI: databee generate ddl --dialect postgres|mysql|sqlite writes DDL for a dialect, by default that of the project. A model of another dialect is emitted from its logical types; what only the other dialect describes is reported as DB-DDL-005 to DB-DDL-009.
  • addedCLI: databee init --dialect postgres|mysql|sqlite starts a project of that dialect; an empty project adopts the dialect of the first pull, a project with objects refuses a connection of another dialect.
  • addedCLI: databee export also reads MySQL, MariaDB and SQLite from a consistent snapshot, with values normalized to the PostgreSQL text forms. sql-insert is written in the dialect of the project; sql-copy is PostgreSQL only (DB-EXP-009).
  • addedCLI: databee lint scopes its rules by dialect: PG001, PG003 and PG014 apply to every dialect, PG002 to PostgreSQL and SQLite, PG005, PG006, PG016 and PG017 to PostgreSQL only.
  • addedProject format: project.toml has an optional dialect (postgres by default) and [extensions.<dialect>] with server settings. Native properties of MySQL and SQLite objects are versioned extensions mysql and sqlite.
  • addedMCP: generate_ddl takes an optional dialect.
  • addedCLI: scripts/db-matrix.sh runs the integration tests against PostgreSQL 15–19, MySQL 8.4 and 9, and MariaDB 10.11 and 11.4 in Docker (DATABEE_TEST_MYSQL_URL, DATABEE_TEST_MARIADB_URL).
  • addedCLI: databee transform --to <dialect> --into <dir> derives a project for another dialect (MySQL, MariaDB or SQLite to PostgreSQL first). Each conversion is exact, equivalent, lossy, manual or unsupported with reason, file and JSON path (DB-TRF-*); model IDs stay the same. Open decisions give exit code 1.
  • addedCLI: databee analyze compatibility --to <dialect> prints the conversion report without writing, and databee analyze fit scores the model for PostgreSQL, MySQL/MariaDB and SQLite with the reason of every deduction.
  • addedProject format: mapping decisions live in mappings/<source>-to-<target>.toml (JSON Schema in .databee/schemas/mapping.schema.json), globally and per column: TINYINT(1), ENUM and SET, BIGINT UNSIGNED, zero dates, DATETIME time zone, case-insensitive unique keys, prefix and FULLTEXT indexes, spatial types.
  • addedMCP: the planner profile adds schema_transform, which writes only below out/transform/<name>/, and schema_analyze.
  • addedCLI: databee generate ddl for PostgreSQL writes CREATE EXTENSION, ICU collations and descending index parts that a transformed project needs.
  • addedCLI: databee migrate plan --from <source> --to <target> plans a migration with data from MySQL, MariaDB or SQLite into PostgreSQL as migrations/<name>.json with a hash: schema, one data step per table in load order, then foreign keys, indexes and sequence values. It refuses open decisions and a source that changed since the transformation (DB-MIG-001).
  • addedCLI: databee migrate preview shows steps, row counts and risks, databee migrate approve records a human approval for the plan hash (terminal only, no --yes), and databee migrate execute copies the data of an approved plan into an empty target in batches from one consistent snapshot, with the value rules applied.
  • addedCLI: databee migrate resume continues an interrupted run after the last committed batch; tables without a usable key are copied again. The progress is kept in the target in the transaction of each batch and mirrored to .databee/migrations/<name>/checkpoint.json.
  • addedCLI: databee migrate verify compares row counts, checksums over normalized values, NULL counts, foreign keys and sequence state of source and target. Differences are DB-MIG-100 to DB-MIG-104 with exit code 1.
  • addedMCP: the planner profile adds migration_plan, migration_preview and migration_verify, the operator profile migration_execute and migration_resume; they take connection profile names, work in out/transform/<name>/ and run only a plan whose current hash a human approved. There is no tool that approves.
  • addedCLI: the zero_date decision of a mapping now also applies to the data of every date column, not only to zero-date defaults (value rule zero_date in transform/data-rules.json).
  • addedCLI: databee pull reads MongoDB 7.0 and 8.0 (mongodb://, mongodb+srv://): collections with their options, $jsonSchema validator and indexes (compound, unique, sparse, TTL, text, partial), and the structure of the documents from a sample. Fields are recursive (embedded objects, arrays), several types in one field are a union with counts, and origin, confidence and the reason stand at the field. Views and sharded collections are reported as DB-INT-001, a partial sample as DB-INT-005.
  • addedCLI: databee pull --sample-size <n> --sample-mode first|random sets the sample of a MongoDB database (1000 documents, random by default). first takes the first documents by _id, so a second pull of unchanged data changes nothing.
  • addedProject format: a field is optional if a document may lack it, which differs from nullable (an explicit null). An inferred field is required only if the validator requires it, or every sampled instance has it and at least 100 documents or the whole collection were sampled. A foreign key can have meta (origin: inferred, confidence): MongoDB references are found where ObjectId values match the _id of another collection, and are never enforced.
  • addedCLI: databee export writes a MongoDB collection as ndjson, one document per line as relaxed Extended JSON ordered by _id; other formats are refused with DB-EXP-010.
  • addedCLI: databee init --dialect mongodb starts a MongoDB project. lint and validate report nothing relational for collections.
  • addedCLI: databee transform converts MongoDB projects to PostgreSQL and back (--to postgres, --to mongodb). Nothing is guessed: each embedded object or array, ObjectId, multi-type field, inferred reference and relationship is a decision in mappings/, manual until decided (DB-TRF-027 to DB-TRF-033), with a recommendation from the access: lines of the domains. The report explains every relationship, including document size and write paths.
  • addedCLI: transform/data-rules.json gets a documents part: rules that cut a document into rows and put rows into documents. explode and assemble in databee-transform apply them; running them against databases is not part of this version.
  • addedCLI: databee generate ddl --dialect mongodb writes a mongosh script for a MongoDB project: createCollection with a $jsonSchema validator (bsonType, required only for required fields, nested properties, array items, enum, maxLength) and createIndex for unique, compound, TTL, text, partial and hashed indexes. The script is deterministic and, applied to an empty database and pulled back, gives the same structure. DB-DDL-011 to DB-DDL-014 report what the script leaves out or builds from a sample.
  • addedCLI: databee analyze fit scores a MongoDB project and adds MongoDB as a fourth target, with the features nested fields, union fields, arrays of objects and optional fields. The capability matrices of all adapters know the capabilities NestedField, UnionField, ArrayField and OptionalField.
  • addedCLI: The JSON Schema export of a MongoDB project describes the ndjson export: an ObjectId is {"$oid": …}, a date {"$date": …}, a decimal {"$numberDecimal": …}.
  • addedProject format: an inferred reference is no constraint anywhere: PostgreSQL, MySQL and SQLite DDL, ALTER plans, migration plans, generated code, lint and DBML leave it out, and the ERD, the dictionary and the rendered diagram show it as inferred (dashed, labeled).
  • addedCLI: scripts/db-matrix.sh runs the integration tests against mongo:7.0 and mongo:8.0 in Docker (DATABEE_TEST_MONGODB_URL).
  • addedCLI: databee export takes a subset. where (a SQL predicate), sample ({ rows = N } or { percent = P, seed = S }) and include_children on a [[data]] entry choose the rows of a root table; the rows they reference are always exported, so every key in the export resolves. subset = "related-only" and dangling = "null" tune the rest; the manifest lists the subset per entity.
  • addedCLI: [data.mask] replaces column values with hash, fake (email, name, phone, iban, text and more), null, constant, shift_date, round or keep_format. Output keeps type and length, keys stay unique, and columns that reference a masked key follow it. The secret is DATABEE_MASK_KEY, never written; without it a run uses a random key. Reports name the strategy per column, never values.
  • addedProject format: a field can be marked sensitive (add_field, alter_field, kept by pull). export check warns (DB-EXP-015) when it is exported without a mask, --strict stops before writing, and names like email get a hint (DB-EXP-016).
  • addedCLI: exports report DB-EXP-011 to DB-EXP-022 for subsets and masks. DB-EXP-001 now means an unsupported combination, such as a mask on a MongoDB collection.
  • addedMCP: export_profile_save, export_check and export_run handle the subset and mask fields, and export_run takes strict.
  • addedCLI: databee generate data makes synthetic test data from the model without a database: --rows rows per entity (or an export profile with generate), foreign keys only to generated parent rows, unique keys, enums and simple checks respected, the same bytes for the same model and --seed. It runs in the load order of an export, in any export format.
  • addedCLI: a [[data]] entry with generate = { rows = N } or { per_parent = "1..5" } makes rows instead of reading them, needs no connection, and [data.columns] sets a fake kind, constant, value list, range or NULL share per column. export check and manifest.json show the plan under generated. Reported as DB-EXP-023 to DB-EXP-027; MongoDB collections are refused (DB-EXP-001).
  • addedMCP: export_profile_save, export_check and export_run accept generating profiles and run them without a connection profile.
  • addedCLI: databee pull reads SQL Server 2022 (mssql://user:password@host:port/database or sqlserver://, ?trust_server_certificate=true for a self-signed certificate) with the Microsoft driver mssql-rs: schemas, tables, columns with types, collations, identity, computed columns, named defaults, checks, keys, foreign keys and MS_Description comments.
  • addedCLI: SQL Server indexes keep their uniqueness, clustering, descending parts, INCLUDE columns and filter. databee init --dialect mssql starts a project, and databee generate ddl writes T-SQL that, run in an empty database and pulled again, gives the same model.
  • addedCLI: pulling SQL Server reports views, routines, triggers, sequences, synonyms, partitioning, columnstore and temporal tables, roles and grants as DB-INT-001; hierarchyid, sql_variant, xml, spatial types and rowversion stay native types.
  • addedCLI: databee export reads SQL Server in one SNAPSHOT (else REPEATABLE READ) transaction and writes csv, ndjson and sql-insert as T-SQL; subsets, samples and masks work as with the other databases.
  • addedCLI: scripts/db-matrix.sh also runs the integration tests against SQL Server 2022 (mssql:2022, alias mssql).
  • addedCLI: databee transform --to postgres and databee analyze compatibility --to postgres take a SQL Server model as the source. Types, identity with start and step, computed columns, filtered indexes with INCLUDE, binary collations and the T-SQL of checks, defaults and filters are converted per class; open choices are the decisions tinyint_range, money, rowversion, computed_column, target_type, spatial and case_insensitive_unique (report codes DB-TRF-034 to DB-TRF-039).
  • addedCLI: the compatibility report lists what SQL Server has and PostgreSQL does not receive: procedures, functions, triggers, views, sequences, synonyms, partitioned and temporal tables, columnstore indexes, roles and grants as unsupported entries (DB-TRF-021) at the object, hierarchyid and sql_variant columns as open decisions. databee pull keeps these objects in project.toml under extensions.mssql for that.
  • addedCLI: databee analyze fit scores SQL Server as a fifth target next to PostgreSQL, MySQL, SQLite and MongoDB, and a SQL Server model as the model to score; SQL Server is not a target of databee transform and says so.
  • addedCLI: databee migrate copies a SQL Server database into PostgreSQL with the same plan, approval, resume and verify as for MySQL: datetimeoffset values are compared as instants, fractions beyond microseconds are cut by a value rule, a rowversion can become a number. scripts/db-matrix.sh mssql passes DATABEE_TEST_CROSS_PG_URL to the SQL Server run.
  • addedMCP: schema_transform, schema_analyze and the migration tools accept a SQL Server project or database as the source.
  • addedProject format: a PostgreSQL identity column can carry identity_start and identity_increment; the DDL writes START WITH and INCREMENT BY.
  • changedStudio: toolbar and side panel fit narrow windows: the project path shrinks instead of hiding the finding counters, and the side panel width follows the window.
  • changedBuild: the minimum supported Rust version is 1.95 (the SQL Server driver needs it).
  • fixedStudio: cargo tauri build and cargo tauri dev now work from studio/ as well as studio/src-tauri.
  • fixedCLI: ALTER plans drop unnamed primary and unique keys of long table or column names by the name PostgreSQL actually gave them.
  • fixedCLI: databee export of a PostgreSQL table sorts rows by the key column itself, no longer by its text form (id 10 came before 2).
  • fixedMySQL: a pulled MySQL 8 project whose checks, computed columns or expression defaults contain string literals produces DDL the server accepts again (the information_schema text carried an extra layer of escapes).
  • fixedCLI: applying a lint or validation fix (--fix) records an undo step, so the fix can be undone and earlier steps stay undoable.
  • fixedStudio: Apply fix records an undo step, so the fix can be undone and earlier steps stay undoable.
  • fixedStudio: Undo is available after a restart and for several steps in a row, and disabled when an outside change prevents it.
  • fixedStudio: lines of different foreign keys no longer share a stretch next to an entity.
  • fixedStudio: a newly created entity is brought into view.
  • fixedStudio: Undo shows why a step cannot be undone instead of "Nothing to undo".
  • fixedStudio: enum types are shown with their namespace in the type picker when the project has several namespaces.
  • fixedStudio: the macOS app bundle builds (minimum macOS 10.15).
  • fixedStudio: dialogs mark their check result as out of date when the project changed on disk.