Syntax for exclude wildcard (glob)

391 views
Skip to first unread message

kare...@gmail.com

unread,
Nov 4, 2016, 5:56:12 PM11/4/16
to Automate
Hi,
I am trying to add a wildcard to a File Copy block that excludes all files/folders whose names include a specific string (e.g. "xyz"). Unfortunately I totally don't understand the syntax as explained in the Automate help. Tried to search here, google elsewhere, nothing that would make it clear to me.
My current state is: File copy (block)/SOURCE PATH/="folder/folder/" glob("xyz,\)
and I get "Expected EOF but found NAME.
oh well...
Can anyone help w this, pls?
:)
K

Florian HubSpace

unread,
Nov 5, 2016, 4:14:49 AM11/5/16
to automa...@googlegroups.com, kare...@gmail.com
Hi.

Glob is well and as short as possible described on wikipedia.

However, according to the documentation of the glob function, [] and [!] is not implemented.

You don´t need to use the glob function within the path value. It won´t work as expected.
You need to provide the path with wildecards as your path.

Example source path: := "Automate/Folder/*/*.t?t"

Result:
Automate/Folder/asd/fgh.txt
Automate/Folder/yxc/vbnaf.tst
Automate/Folder/qwe/rtzu.t3t
Automate/Folder/starCanAlsoMeanNoCharacter/.tnt

Henrik "The Developer" Lindqvist

unread,
Nov 5, 2016, 6:07:01 AM11/5/16
to Automate, kare...@gmail.com
File copy block...
Source path: folder/folder/*xyz*

kare...@gmail.com

unread,
Nov 5, 2016, 6:54:30 AM11/5/16
to Automate, kare...@gmail.com
Thank you both guys for replying, but how does it solve my EXCLUDE (opposite to INCLUDE) needs?
I will read the wikipedia article through and through again and maybe something will hit.
Best,
K

Henrik "The Developer" Lindqvist

unread,
Nov 5, 2016, 8:12:30 AM11/5/16
to Automate, kare...@gmail.com
For more elaborate file matching you'll have to use the File list block, and then process the array of paths using the disjoint, etc. functions.

kare...@gmail.com

unread,
Nov 5, 2016, 9:18:28 PM11/5/16
to Automate, kare...@gmail.com
Thank you very much for your reply. I wrongly assumed the "\" will exclude files.

Reply all
Reply to author
Forward
0 new messages