To get a list of the files in directory /tmp/abcd:
set file_list [glob -nocomplain /tmp/abcd/*]
To write the list to a file, simply open a file for write and run through file_list with a foreach. If you need more info than just the file name, you can use the "file" command to get file type, permissions, etc.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.