diff --git a/src/Maker/BundleFileMaker.php b/src/Maker/BundleFileMaker.php index fd139a5..f32cd1e 100644 --- a/src/Maker/BundleFileMaker.php +++ b/src/Maker/BundleFileMaker.php @@ -65,5 +65,7 @@ public function make(BundleOptions $options): void 'vendor-prefix' => Inflector::vendory($options->name), ], sprintf('translations/%s.fr.xlf', Inflector::className($options->name))); } + + $this->fileCreator->create('.gitattributes'); } } diff --git a/templates/.gitattributes.template b/templates/.gitattributes.template new file mode 100644 index 0000000..1b5973d --- /dev/null +++ b/templates/.gitattributes.template @@ -0,0 +1,5 @@ +.gitattributes export-ignore +.gitignore export-ignore +.github export-ignore +docs export-ignore +tests export-ignore diff --git a/tests/Maker/BundleFileMakerTest.php b/tests/Maker/BundleFileMakerTest.php index 8097e22..23e9dab 100644 --- a/tests/Maker/BundleFileMakerTest.php +++ b/tests/Maker/BundleFileMakerTest.php @@ -37,6 +37,7 @@ public function testCreateBundleFilesWithCorrectContent(): void $this->assertGenFile('templates/hello.html.twig'); $this->assertGenFile('translations/FooBundle.fr.xlf'); $this->assertGenFile('README.md'); + $this->assertGenFile('.gitattributes'); } public function testThrowsExceptionWhenUnableToCreateReadmeFile(): void