From 94a47c286b6b7866770f535d1b462ae45c0385d8 Mon Sep 17 00:00:00 2001 From: Eli Schwartz Date: Thu, 23 Jan 2025 00:52:31 -0500 Subject: [PATCH] Force various files to be skipped when generating git archives Meson utilizes `git archive` as the first step in producing a release tarball. Certain files don't need to be distributed in release tarballs at all -- namely, files used by git itself, or by github when processing a git repository for e.g. CI purposes. They have no use case outside of a git repo -- not even as documentation. Exclude these files from the tarball. This affects both `meson dist` and the github autogenerated tarballs on the Tags page. More work is needed to have `meson dist` reach parity with automake's `make distcheck`, but this is a start. --- .gitattributes | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/.gitattributes b/.gitattributes index 367d91c24d..e7cf8a0c1c 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1,2 +1,10 @@ # https://github.com/github/linguist/blob/master/docs/overrides.md */zones/* linguist-language=DNS-Zone + +# not needed in `git archive` tarballs, only in raw git clones +.gitattributes export-ignore +.gitmodules export-ignore +.gitignore export-ignore + +.github export-ignore +.circleci export-ignore -- 2.47.2