Re:Ox is a fast text editor, written in Rust, that runs in y...
by ploxiln on Tuesday November 03, 2020 @04:14AM
(#24977889)
I noticed some years ago that vim can be much slower due to highlighting of particular syntax of huge files. For example it was fine with a 10MiB C file, but super slow with a 10MiB XML file, but fast again with ":syntax off"
Re:Ox is a fast text editor, written in Rust, that runs in y...
by _djo_ on Tuesday November 03, 2020 @04:19AM
(#24977913)
Are you doing the formatting via a Vim plugin?
I often find it's much faster to pipe out to a command line program to do formatting on huge files.
e.g.
:%! jq
or :%! xmllint --format -
Re:Ox is a fast text editor, written in Rust, that runs in y...
by OJFord on Tuesday November 03, 2020 @10:05AM
(#24980253)
Huh, thanks, I didn't know you could put the contents on stdin like that (%!) - just in case you (or anyone) was similarly unaware in reverse, you can also put `%` wherever you want to use the filename in the command.
i.e. I would have done:
:! jq %
and have probably been guilty of (not knowing `%!` per above): :! cat % | ...
My beloved vim doesn't fair so we'll. VScode does very well on this.