From 3b988f6790760d486d5bea2175c48cb5ca0ccc45 Mon Sep 17 00:00:00 2001 From: Michael Vetter Date: Fri, 20 Mar 2026 14:03:52 +0100 Subject: [PATCH] build: add .gitattributes to exclude development files from exports This will result in smaller and cleaner tarballs for distributions to use. Additionally it is a logical step towards moving fully to the Meson build system. While the last release provided two tarballs (one generated with Autotools and one with Meson), the next release will only provide a Meson-generated tarball. These attributes are respected by `git archive` and `meson dist` which means they will take effect for the Meson generated tarballs and the GitHub autogenerated tarballs as well. As a consequence of switching to `meson dist`, pre-generated files like `configure` will no longer be included in the tarballs. Users and distributions that still wish to use the Autotools build system from these tarballs will now need to run `./bootstrap.sh` or `autoreconf -fi` themselves, which requires automake, autoconf, and libtool to be installed. Since many distributions are slowly dropping the usage of vendor generated tarballs and are moving to checking out git tags this should not be a problem. Arch Linux is for example doing `source=("git+https://github.com/user/project.git#tag=v1.2.3")` and Debian has the `git-buildpackage` too. So both of them require require autoreconf already. Autotools support might be removed entirely in a future release since I find them much easier to edit and maintain. --- .gitattributes | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 .gitattributes diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 00000000..e70cd0c0 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,10 @@ +# Pattern Attribute +.clang-format export-ignore +.codespellrc export-ignore +.git-blame-ignore-revs export-ignore +.github/* export-ignore +CONTRIBUTING.md export-ignore +RELEASE_GUIDE.md export-ignore +ci/* export-ignore +prof.supp export-ignore +scripts/* export-ignore