Forum: CFEngine Help
Subject: exclude git directories
Author: tuibelgium
Link to topic: https://cfengine.com/forum/read.php?3,25335,25335#msg-25335

I want to copy a directory which is a git repository whithout the .git 
directory.
The example below copies the git directory. Is there something wrong with the 
regex ".*\.git.*" ?
I already tried different combinations, every time the git directory is copied.


files:
        "/tmp/dir"
        copy_from => my_cp("${source}"),
        depth_search => recurse("inf"),
        file_select => exclude_git;
}
############################################################
body file_select exclude_git
{
leaf_name => { ".*\.git.*" };
file_result => "!leaf_name";
}


_______________________________________________
Help-cfengine mailing list
Help-cfengine@cfengine.org
https://cfengine.org/mailman/listinfo/help-cfengine

Reply via email to