From 83fa3bf2a7a86536aa1c1a25a49df0da6593361c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Denis=20=C5=BDoljom?= Date: Fri, 11 Oct 2024 13:54:21 +0200 Subject: [PATCH] Add gitattributes file I noticed that on downloading the package via Composer the package loaded unnecessary files (scripts, tests, config for phpcs and phpstan). By adding .gitattributes file, we can exclude the addition of these files and folders and save people some bandwidth :D --- .gitattributes | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 .gitattributes diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 00000000..443178f3 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,22 @@ +# +# Exclude these files from release archives. +# This will also make them unavailable when using Composer with `--prefer-dist`. +# https://blog.madewithlove.be/post/gitattributes/ +# +/.gitattributes export-ignore +/.gitignore export-ignore +/phpcs.xml export-ignore +/phpstan.neon export-ignore +/phpstanbootstrap.php export-ignore +/phpunit.xml export-ignore +/.github export-ignore +/scripts export-ignore +/tests export-ignore + +# +# Auto detect text files and perform LF normalization +# https://pablorsk.medium.com/be-a-git-ninja-the-gitattributes-file-e58c07c9e915 +# +* text=auto + +*.php text