ship
ship copied to clipboard
Improve UX around existing file paths
This is a big issue and warrants some deeper design. Right now if ship wants to write a file to installer/
or base/
or any other directory, and that directory exists, everything blows up.
Do you know if this happens with ship update
or just ship init
? Because IMO that would really break update...
I think ship update
and other headless workflows will automatically copy folders to .bak
before overwriting. We can talk about doing this for headed installs too, but it means you only get one rollback. We used to copy to .bak.TIMESTAMP
but that got really gross.
I'm thinking of something a little cleaner like tracking ship-generated files in .ship/state.json
with their checksums, or staging things out somewhere in .ship
before copying out into the CWD. I don't know. There's a lot of options and probably a decent amount of prior art here.