Skip to content

Don't rename file to backup file on save: instead copy it #12046

@aster-void

Description

@aster-void

see helix-view/document.rs :959 for the code

it is causing too many issues:

  • vite watch fails to detect changes
  • inotifywatch fails to detect writes
  • file perms change on save / see Writing changes file ownership #11988
  • hard link breaks (even though it's explicitly checked??)

and it doesn't serve much purpose because:

  • doesn't save disk space because the file is overwritten instantly
  • we don't edit gigabytes of file very often

if the speed is critical on large files, move it only when the file is that large.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions