Closed oalders closed 2 years ago
Right now I think the order is undefined, because the config is put into a Rust HashMap
that I iterate over. But switching this to a Vec<(String, Command)
would be pretty easy. Do you have any interest in making a PR?
That sounds like a fun project. I've read a bit of the Rust Book, but that's about it, so maybe this is a good place to start.
Looking at the code, this is a pretty trivial change. But it'd be good to add some tests to make sure that the config file order is preserved.
I realized there's a much simpler way to do this, which is to just use a drop-in ordered map replacement. I'm working on that now.
Done in v0.1.2
I apologize if I have missed this in the docs. I'd like to ensure that
perlimports
always runs beforeperltidy
as the file may need to be tidied after the imports have been rewritten.Is it possible to dictate an arbitrary order in which files get tidied when running
precious tidy --all
?