Skip to content

Commit

Permalink
feat: add .gitattribute to skeleton
Browse files Browse the repository at this point in the history
  • Loading branch information
mtarld committed Feb 15, 2024
1 parent 14e93a5 commit 9a60b45
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/Maker/BundleFileMaker.php
Original file line number Diff line number Diff line change
Expand Up @@ -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');
}
}
5 changes: 5 additions & 0 deletions templates/.gitattributes.template
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
.gitattributes export-ignore
.gitignore export-ignore
.github export-ignore
docs export-ignore
tests export-ignore
1 change: 1 addition & 0 deletions tests/Maker/BundleFileMakerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down

0 comments on commit 9a60b45

Please sign in to comment.