Skip to content

fix(install): preserved-file template diffs render as symlink add/delete, not content diffs #1349

Closed

Description

@c-vigo

Problem

On --force upgrades the installer prints a diff between each preserved consumer file and the incoming template so the consumer can fold in template evolution (MIGRATION.md 0.3.x checklist item 2). But devkit's assets are nix-store symlinks, so every one of these diffs renders as "symlink deleted / workspace file added" instead of an actual content comparison — the diff is useless for its stated purpose.

Observed on the vig-os/scitadel 0.3.3 → 1.6.0 migration (issue vig-os/scitadel#207): all four preserved-file diffs (.pre-commit-config.yaml among them) had to be redone by hand against devkit/assets/workspace/.

Expected

Dereference the template side (e.g. diff -L template <(cat "$(readlink -f "$tpl")") "$consumer_file" or --no-dereference-aware handling) so the printed diff compares contents.

Workaround

Manually diff the preserved file against the resolved file under assets/workspace/ in the devkit checkout.

Activity

  1. added
    bug
    area:workspace
    effort:small
    on Aug 7, 2026
  2. added this to the 1.6.1 milestone on Aug 7, 2026
  3. added
    priority:medium
    semver:patch
    on Aug 7, 2026
  4. c-vigo commented on Aug 7, 2026

    @c-vigo
    ContributorAuthor

    Fixed on dev by PR #1354: the preserved-file template diff now dereferences symlinked templates (content materialized under the file's own name in a temp dir), so --force upgrades print a real content diff instead of a symlink typechange. Ships with the next devkit release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:workspacebugeffort:smallpriority:mediumsemver:patch

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions