tags:

views:

25

answers:

1

I have some code that is dependent on the fact that (until now) I've been getting the results by find in cygwin in ascending order.

Is this always the case or have I to be careful about any other "variables", to make sure I will get this result in both Windows / Linux, whatever?

Thanks

+1  A: 

First, bash is your shell (command line interpreter) and does not sort. Inside of bash you invoke find. The command find does not sort. For a sorted result pipe to sort:

find ... | sort
Peter G.