helix/helix-view/src
Michael Davis 855568fa34
Synchronize files after writing (#10735)
fsync(2) is a somewhat expensive operation that flushes writes to the
underlying disk/SSD. It's typically used by databases to ensure that
writes survive very hard failure scenarios like your cat kicking the
plug out of the wall. Synchronizing isn't automatically done by
`flush`ing (from the `std::io::Write` or `tokio::io::AsyncWriteExt`
traits). From the [`tokio::fs::File`] moduledocs:

> To ensure that a file is closed immediately when it is dropped, you
> should call `flush` before dropping it. Note that this does not ensure
> that the file has been fully written to disk; the operating system
> might keep the changes around in an in-memory buffer. See the
> `sync_all` method for telling the OS to write the data to disk.

[`tokio::fs::File`]: https://docs.rs/tokio/latest/tokio/fs/struct.File.html
2024-05-14 01:37:35 +02:00
..
handlers Remove unwrap on line option, preventing DAP crash (#9632) 2024-02-16 15:43:14 +01:00
base64.rs Fix new clippy lints (#5892) 2023-02-09 16:27:08 -06:00
clipboard.rs FIx incorrectly spelled cfg options (#10703) 2024-05-07 18:14:02 +02:00
document.rs Synchronize files after writing (#10735) 2024-05-14 01:37:35 +02:00
editor.rs FIx incorrectly spelled cfg options (#10703) 2024-05-07 18:14:02 +02:00
events.rs Add hook/event system 2024-01-23 11:20:19 +09:00
graphics.rs build(deps): bump bitflags from 1.3.2 to 2.0.2 (#6387) 2023-03-22 08:12:08 +08:00
gutter.rs use newtype parttern for langauge server id 2024-04-22 12:27:47 +09:00
handlers.rs refactor completion and signature help using hooks 2024-01-23 11:20:19 +09:00
info.rs Use refactored Registers type 2023-07-31 15:05:38 +09:00
input.rs Normalize `S-<lower-ascii>` keymaps to uppercase ascii (#9213) 2024-01-09 10:04:34 +09:00
keyboard.rs build(deps): bump bitflags from 1.3.2 to 2.0.2 (#6387) 2023-03-22 08:12:08 +08:00
lib.rs Re-export `which` from `helix-stdx::env` 2024-01-24 15:47:49 +09:00
macros.rs Apply transactions to all views (#4733) 2022-11-23 12:28:49 +09:00
register.rs `cargo fmt` 2024-05-07 15:15:52 -04:00
theme.rs Add tree-sitter-highlight-name command (#8170) 2023-09-10 14:57:44 +02:00
tree.rs Resolve new Clippy lints 2024-05-07 15:15:52 -04:00
view.rs show newest options in jumplist picker first, fix docs (#10095) 2024-04-02 16:39:44 +02:00