protected function copyFiles(InputInterface $input, OutputInterface $output)
    {
        $output->writeln('<comment>Copy files from the environment directory</comment>');

        $fs = new Filesystem();

        $directoryIterator = new \RecursiveDirectoryIterator($this->dir, \RecursiveDirectoryIterator::SKIP_DOTS);
        $iterator = new \RecursiveIteratorIterator($directoryIterator, \RecursiveIteratorIterator::SELF_FIRST);

        foreach ($iterator as $item) {
            if (in_array($iterator->getSubPathName(), $this->excludedFiles)) {
                continue;
            }

            $itemPath = $this->getApplication()->getRoot() . '/' . $iterator->getSubPathName();

            if ($item->isDir()) {
                $fs->mkdir($itemPath);
            } else {
                $fs->copy($item, $itemPath, true);
            }

            $output->writeln('   ' . $itemPath);
        }
    }
protected function copyFiles(InputInterface $input, OutputInterface $output)
    {
        $output->writeln('<comment>Copy files from the environment directory</comment>');

        $fs = new Filesystem();

        $directoryIterator = new \RecursiveDirectoryIterator($this->dir, \RecursiveDirectoryIterator::SKIP_DOTS);
        $iterator = new \RecursiveIteratorIterator($directoryIterator, \RecursiveIteratorIterator::SELF_FIRST);

        foreach ($iterator as $item) {
            if (in_array($iterator->getSubPathName(), $this->excludedFiles)) {
                continue;
            }

            $itemPath = $this->getApplication()->getRoot() . '/' . $iterator->getSubPathName();

            if ($item->isDir()) {
                $fs->mkdir($itemPath);
            } else {
                $fs->copy($item, $itemPath, true);
            }

            $output->writeln('   ' . $itemPath);
        }
    }
protected function copyFiles ( InputInterface $ input , OutputInterface $ output ) { $ output -> writeln ( '<comment>Copy files from the environment directory</comment>' ) ; $ fs = new Filesystem ( ) ; $ directoryIterator = new \ RecursiveDirectoryIterator ( $ this -> dir , \ RecursiveDirectoryIterator :: SKIP_DOTS ) ; $ iterator = new \ RecursiveIteratorIterator ( $ directoryIterator , \ RecursiveIteratorIterator :: SELF_FIRST ) ; foreach ( $ iterator as $ item ) { if ( in_array ( $ iterator -> getSubPathName ( ) , $ this -> excludedFiles ) ) { continue ; } $ itemPath = $ this -> getApplication ( ) -> getRoot ( ) . '/' . $ iterator -> getSubPathName ( ) ; if ( $ item -> isDir ( ) ) { $ fs -> mkdir ( $ itemPath ) ; } else { $ fs -> copy ( $ item , $ itemPath , true ) ; } $ output -> writeln ( '   ' . $ itemPath ) ; } }
Copy files and directories from the environment directory to application.

@param InputInterface $input
@param OutputInterface $output
Copy files and directories from the environment directory to application .