Commit ff1cbf5
committed
Add buildroot.py for self-contained sources.buildroot.net mirror
sources.buildroot.net (the official Buildroot backup site) has
permanently disabled directory listing (Cloudflare 403). Neither rsync,
tsumugu, nor wget -m can discover what files exist on the server.
This script clones the buildroot git tree, extracts the download URL
for every package directly from the .mk files, and downloads only new
or changed files. Existing local data is preserved (no deletion unless
explicitly enabled).
Steps:
1. Shallow-clone buildroot master
2. Parse boot/*.mk, linux/*.mk, package/*/*.mk for VERSION, SITE, SOURCE
3. Expand version variables and macro calls (github, gitlab, sourceforge)
4. Compare each candidate URL against the local mirror
5. Download new/changed files atomically (.tmp -> rename)
6. Clean up stale files up to TUNASYNC_BUILDROOT_MAXDELETE
GitHub API rate-limit is avoided by using archive tarball URLs.
SourceForge redirects are followed by wget, not by the script.1 parent 93b8cff commit ff1cbf5
1 file changed
Lines changed: 424 additions & 0 deletions
0 commit comments