fshost / node-dir

Recursive asynchronous file and directory operations for Node.js
MIT License
221 stars 44 forks source link

Case insensitive sorting. #34

Open octopuss opened 8 years ago

octopuss commented 8 years ago

Hi,

I like your project, and I'm trying to use it in one of my projects. Is there a possibility to add sorting function to the options, so the result will be sorted by it ? I'd like to have the file system sorted case insensitively.

I think that there will be only slight change in your code to allow that - just allow to pass function from options to the list.sort

https://github.com/fshost/node-dir/blob/master/lib/readfilesstream.js#L86

Thank you.