Sashmark / Help

Sashmark is in development. Nothing has been released yet, and there is no public build. These pages describe the development build. See the roadmap for what is still planned.

How Skimmark saves a file

Press Cmd/Ctrl+S to save your edits (see Editing and saving a file). This page explains what every save does.

It never overwrites a change you haven't seen

Before it writes, Skimmark checks that the file on disk is still the version you opened. It checks again at the last moment, right before the new version replaces the old one. If an AI agent (or anything else) changed the file since you opened it, Skimmark doesn't save. The agent's version stays on disk exactly as it wrote it, and you choose between Keep mine and Load theirs (see When an agent changes a file you are editing). After Keep mine, a save replaces the agent's version you chose to overwrite, and only that one: a newer change is refused again.

If two saves of the same file start at once, they run one after the other, even when the file is reached by two different spellings of its path (a symbolic link, ./, or different letter case on Mac and Windows). The second one sees the first one's change and is refused the same way.

Skimmark only saves files it has open in a tab.

It never leaves a half-written file

Skimmark writes the new version to a hidden file in the same folder (named .skm- followed by numbers, ending in .tmp), makes sure it is fully on disk, and only then swaps it in for the old file. If the app crashes or the computer loses power during a save, the file is either the old version or the new one, never a mix. A hidden file left behind by a crash is removed the next time you save a file in that folder.

The saved file keeps the old file's permissions.

What a save replaces

Because the new version replaces the old file rather than writing into it, the saved file is a new file with the same name. That means:

  • Hard links: a file that has another name (a hard link) is not saved, because the other name would keep the old text.
  • Other file details are not copied: Finder tags and other extended attributes on Mac, and Windows access lists set on the file itself, are not carried over. The new file gets the folder's defaults. The file's owner can change if someone else owned it.

It writes your text exactly

Line endings (including Windows-style CRLF), a missing newline at the end, and a byte order mark at the start are all kept as they are.

When a save is refused

Reason What happened
The file changed on disk Something else wrote the file after you opened it (or, after Keep mine, wrote it again). Nothing was saved.
Permission denied The file is read-only, or you aren't allowed to write it or its folder. Nothing was saved.
File busy Another program held the file open the whole time Skimmark tried. Nothing was saved; try again.
Hard links The file has another name (a hard link). Nothing was saved.
Not found The file or its folder was deleted or moved. Skimmark doesn't recreate it.
Not open The file isn't open in a tab. Nothing was saved.

On Windows, another program (often antivirus or the search indexer) can hold a file open for a moment. Skimmark tries again a few times over a quarter of a second, then refuses with "File busy". The file keeps its old version.

When the save isn't fully confirmed

Rarely, the new version is in place but the computer can't confirm that the swap itself is safely stored on disk (the folder sync failed). The save still counts: the file is the complete new version. If the computer then lost power before the disk caught up, the old version could come back.

View as Markdown