m/windows: Copied windows_sort code from file_order.rb