self_update
self_update copied to clipboard
How to restart the process to update?
On Unix it's possible to replace the current process with the updated version using https://doc.rust-lang.org/stable/std/os/unix/process/trait.CommandExt.html#tymethod.exec. Could this crate provide mechanisms for other platforms?
The closest thing I could find is https://github.com/lichess-org/fishnet/blob/90f12cd532a43002a276302738f916210a2d526d/src/main.rs#L428-L439, which is good enough for my use case, but not a general purpose solution.
Thank you very much, your workaround is pretty nice. Would be awesome if self_update handles the restart part automatically.