protected function checkIgnored($filename, $suggestion = null)
    {
        if (!file_exists($filename)) {
            return;
        }
        if (!$repositoryDir = $this->gitHelper->getRoot($this->appRoot)) {
            return;
        }
        $relative = $this->fsHelper->makePathRelative($filename, $repositoryDir);
        if (!$this->gitHelper->checkIgnore($relative, $repositoryDir)) {
            $suggestion = $suggestion ?: $relative;
            $this->stdErr->writeln("<comment>You should exclude this file using .gitignore:</comment> $suggestion");
        }
    }
protected function checkIgnored($filename, $suggestion = null)
    {
        if (!file_exists($filename)) {
            return;
        }
        if (!$repositoryDir = $this->gitHelper->getRoot($this->appRoot)) {
            return;
        }
        $relative = $this->fsHelper->makePathRelative($filename, $repositoryDir);
        if (!$this->gitHelper->checkIgnore($relative, $repositoryDir)) {
            $suggestion = $suggestion ?: $relative;
            $this->stdErr->writeln("<comment>You should exclude this file using .gitignore:</comment> $suggestion");
        }
    }
protected function checkIgnored ( $ filename , $ suggestion = null ) { if ( ! file_exists ( $ filename ) ) { return ; } if ( ! $ repositoryDir = $ this -> gitHelper -> getRoot ( $ this -> appRoot ) ) { return ; } $ relative = $ this -> fsHelper -> makePathRelative ( $ filename , $ repositoryDir ) ; if ( ! $ this -> gitHelper -> checkIgnore ( $ relative , $ repositoryDir ) ) { $ suggestion = $ suggestion ? : $ relative ; $ this -> stdErr -> writeln ( "<comment>You should exclude this file using .gitignore:</comment> $suggestion" ) ; } }
Check that an application file is ignored in .gitignore.

@param string $filename
@param string $suggestion
Check that an application file is ignored in . gitignore .