Gimp-Forum.net
file-glob & sub folders - Printable Version

+- Gimp-Forum.net (https://www.gimp-forum.net)
+-- Forum: GIMP (https://www.gimp-forum.net/Forum-GIMP)
+--- Forum: Extending the GIMP (https://www.gimp-forum.net/Forum-Extending-the-GIMP)
+---- Forum: Scripting questions (https://www.gimp-forum.net/Forum-Scripting-questions)
+---- Thread: file-glob & sub folders (/Thread-file-glob-sub-folders)



file-glob & sub folders - TimHaydnJones - 05-24-2019

Is it possible to have file-glob traverse sub-folders?
If not, are there any online examples you can point me at where someone has implemented a work-around?

TIA


RE: file-glob & sub folders - Ofnuts - 05-24-2019

https://stackoverflow.com/questions/7806198/how-to-get-a-list-of-files-jpg-from-all-folders

Another solution is to come to the 3rd millennium and write your script in Python, where this functionality is part of the language.


RE: file-glob & sub folders - TimHaydnJones - 05-24-2019

(05-24-2019, 11:26 AM)Ofnuts Wrote: https://stackoverflow.com/questions/7806198/how-to-get-a-list-of-files-jpg-from-all-folders

Another solution is to come to the 3rd millennium and write your script in Python, where this functionality is part of the language.

Much appreciated Ofnuts - you'll be asking me to stop using my VHS next!  Wink


RE: file-glob & sub folders - Ofnuts - 05-24-2019

(05-24-2019, 02:33 PM)TimHaydnJones Wrote:
(05-24-2019, 11:26 AM)Ofnuts Wrote: https://stackoverflow.com/questions/7806198/how-to-get-a-list-of-files-jpg-from-all-folders

Another solution is to come to the 3rd millennium and write your script in Python, where this functionality is part of the language.

Much appreciated Ofnuts - you'll be asking me to stop using my VHS next!  Wink

Scheme is more like Betamax, technically superior to things of the same era, but didn't find its market Smile

My kids would call that black-and-white programming (refering to the movies of the 1st half of the 20th century).


RE: file-glob & sub folders - neurolurker - 05-25-2019

Ofnuts, thank you for clarifying. Being new to GIMP but wanting to stay with it, I've gone from "leaning toward almost ready to start thinking about maybe putting some serious time into learning Python instead of Scheme" to happily convinced.


RE: file-glob & sub folders - Ofnuts - 05-25-2019

(05-25-2019, 03:14 PM)neurolurker Wrote: Ofnuts, thank you for clarifying.  Being new to GIMP but wanting to stay with it, I've gone from "leaning toward almost ready to start thinking about maybe putting some serious time into learning Python instead of Scheme" to happily convinced.

Good.

In practice,  as far as I can tell there is one single person in the world who uses script-fu Scheme as it should be used (he is of course a strong proponent of Scheme and deeply despises Python). Scripts from all other authors look more or less like they are trying to evade Script-fu to use more "classic" forms of programming.