diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index af086c7..fcdc844 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -2,7 +2,7 @@ name: CI on: push: - branches: [3.x, 4.x, 5.x] + branches: [3.x, 4.x, 5.x, 6.x] pull_request: branches: ['*'] workflow_dispatch: diff --git a/src/Command/FileRenameCommand.php b/src/Command/FileRenameCommand.php index 54b5bb1..6a5e692 100644 --- a/src/Command/FileRenameCommand.php +++ b/src/Command/FileRenameCommand.php @@ -27,6 +27,7 @@ use RecursiveRegexIterator; use RegexIterator; use RuntimeException; +use UnexpectedValueException; /** * Rename and move files @@ -207,11 +208,15 @@ protected function renameSubFolders(string $path): void RecursiveRegexIterator::SPLIT, ); - foreach ($templateDirs as $val) { - $this->renameWithCasing( - $val[0] . '/' . $folder, - $val[0] . '/' . strtolower($folder), - ); + try { + foreach ($templateDirs as $val) { + $this->renameWithCasing( + $val[0] . '/' . $folder, + $val[0] . '/' . strtolower($folder), + ); + } + } catch (UnexpectedValueException) { + // No matching folders found } } }