function Archive_Tar::setIgnoreList

This method sets the regular expression for ignoring all files and directories matching the filenames in the array list at import, for example: $arch->setIgnoreList(array('CVS', '.svn', 'bin/tool'));

@access public

Parameters

array $list a list of file or directory names to ignore:

File

modules/system/system.tar.inc, line 793

Class

Archive_Tar

Code

public function setIgnoreList($list) {
    $list = str_replace(array(
        '#',
        '.',
        '^',
        '$',
    ), array(
        '\\#',
        '\\.',
        '\\^',
        '\\$',
    ), $list);
    $regexp = '#/' . join('$|/', $list) . '#';
    $this->setIgnoreRegexp($regexp);
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.