hi,
can I tell to "ls" to list files in the order they were given on the parameter list?
I mean instead of:
Code:
$ ls -al list_1 list_2 list_10
-rw-r--r-- 1 userx staff 0 Nov 19 19:18 list_1
-rw-r--r-- 1 userx staff 0 Nov 19 19:18 list_10
-rw-r--r-- 1 userx staff 0 Nov 19 19:18 list_2
get:
Code:
$ ls -al list_1 list_2 list_10
-rw-r--r-- 1 userx staff 0 Nov 19 19:18 list_1
-rw-r--r-- 1 userx staff 0 Nov 19 19:18 list_2
-rw-r--r-- 1 userx staff 0 Nov 19 19:18 list_10
$
until now I need to sort it like:
Code:
$ ls -al list_1 list_2 list_10|sort -n -t _ -k 2,2
-rw-r--r-- 1 userx staff 0 Nov 19 19:18 list_1
-rw-r--r-- 1 userx staff 0 Nov 19 19:18 list_2
-rw-r--r-- 1 userx staff 0 Nov 19 19:18 list_10
$
can the sort (or any other extra) command be omited and use "some" embedded ls feature to achieve this?