Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Capture diffs of dist tarballs vs auto-generated source archives from GitHub #833

Draft
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

bwarden
Copy link
Member

@bwarden bwarden commented Apr 15, 2024

Highlight files that are different or only present in the release-manager-provided distribution tarballs on GitHub repositories vs. the tarball that GitHub automatically generates for the corresponding tag.

@bwarden
Copy link
Member Author

bwarden commented Apr 15, 2024

Using diff -u -r <main_src> <autogenerated_src>, so we currently don't emit contents of files that exist only in one or the other.

When run against a couple of sample packages, the results look like:

libunibreak

diff --git a/archive.diff b/archive.diff
new file mode 100644
index 000000000000..3c12e25b0faa
--- /dev/null
+++ b/archive.diff
@@ -0,0 +1,20 @@
+Only in libunibreak-5.1: aclocal.m4
+Only in autogenerated/libunibreak-libunibreak_5_1: autogen.sh
+Only in autogenerated/libunibreak-libunibreak_5_1: bootstrap
+Only in autogenerated/libunibreak-libunibreak_5_1: .clang-format
+Only in libunibreak-5.1: compile
+Only in libunibreak-5.1: config.guess
+Only in libunibreak-5.1: config.h.in
+Only in libunibreak-5.1: config.sub
+Only in libunibreak-5.1: configure
+Only in libunibreak-5.1: depcomp
+Only in libunibreak-5.1: doc
+Only in autogenerated/libunibreak-libunibreak_5_1: .gitignore
+Only in libunibreak-5.1: install-sh
+Only in libunibreak-5.1: ltmain.sh
+Only in libunibreak-5.1: m4
+Only in autogenerated/libunibreak-libunibreak_5_1: .mailmap
+Only in libunibreak-5.1: Makefile.in
+Only in libunibreak-5.1: missing
+Only in autogenerated/libunibreak-libunibreak_5_1: purge
+Only in libunibreak-5.1/src: Makefile.in

zstd (no difference between the official release tarball and the tag-based auto-generated tarball)

diff --git a/archive.diff b/archive.diff
new file mode 100644
index 000000000000..e69de29bb2d1

@bwarden
Copy link
Member Author

bwarden commented Apr 15, 2024

Need to figure out how to handle the prefix so we don't get a big diff just from the source version number changing.

@bwarden bwarden requested review from bryteise and fenrus75 April 15, 2024 22:24
@bwarden bwarden force-pushed the compare-github-tarballs branch from 815d806 to 2cf51dd Compare April 15, 2024 22:54
@bwarden bwarden marked this pull request as ready for review April 15, 2024 23:04
@bwarden
Copy link
Member Author

bwarden commented Apr 15, 2024

Don't feel rushed to merge this; I'm looking for any input on the approach.

@bwarden bwarden marked this pull request as draft April 15, 2024 23:48
bwarden added 2 commits April 15, 2024 16:59
We only use this for source tree comparison, not part of the build, so
don't add it to the upstreams file.
Also include content of added files.
@bryteise
Copy link
Member

When you think this is about ready, would you mind squashing it?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants