|Create a list of images in a text file inside a script
|Page 1 of 1|
|Author:||Wall-e-llaW [ Wed Sep 10, 2008 3:49 am ]|
|Post subject:||Create a list of images in a text file inside a script|
Hi, I would like to create a list of images contained in a folder (ex: /home/Imag). The text file should looks as follows:
# the first line should indicate the number of images in the folder
#the next lines should indicate the path and the name of the imgages with the file extension
Anybody can help me? Thanks all!!!
|Author:||myownshadow [ Wed Sep 10, 2008 5:37 am ]|
something like this ?
ls /home/Imag/ | wc -l >list.txt
find /home/Imag/ -type f >> list.txt
|Author:||Wall-e-llaW [ Wed Sep 10, 2008 8:35 am ]|
Yeah! That worked
And if I want to call a method that has as arguments the list.txt created and the number of images in that list, how can I do this?
Ex: the method should be called like this: ./move list numImag
Thank you for your help myownshadow
|Author:||Wall-e-llaW [ Wed Sep 10, 2008 10:12 am ]|
Forget it, I got it!!
It was quite easy
|Page 1 of 1||All times are UTC - 6 hours|
|© 2000, 2002, 2005, 2007 phpBB Group • http://www.phpbb.com|