Hi all, some months ago, I was frustrated with our git_to_httpup script. That script is run every 5 minutes and exports our ports repositories' contents to ~crux/git-to-rsync-working-copy directory structure. Which looks like this: git-to-rsync-working-copy |---crux-2.4 |---core |--- udev |--- rsync |--- ... |---opt |--- ... |---crux-2.5 |---core |--- ... |---opt |--- ... It annoys me that we're exporting *everything* every 5 minutes. I'd prefer if we exported only those repositories that changed, *when* they change, i.e. when some commit is pushed to the repository. This means we'd have to adjust the script that does the exporting. I suggest to make use of git's post-update hook there. That hook would run as the user who does the push, so the httpup area has to be writable by that user. Long story cut short, here's the new directory hierarchy: git-to-rsync-working-copy2 |---core (owned by core) |---2.4 |--- udev |--- rsync |--- ... |---2.5 |--- ... |---opt (owned by opt) |---2.4 |--- ... |---2.5 |--- ... Since we'd switch from "crux-2.4/core" style directories to "core/2.4" or something, we'd have to adjust our *.rsync files. Also we'd need to keep the old rsync area alive for users who are still running old CRUX systems. Advantages: o Updated ports are rsync-able after a very short time and not just after up to 5 minutes. o No more disk thrashing just because another 5 minutes went by even though there was no git activity. Disadvantages: o We'd have to adjust the *.rsync files. Would be doable with the CRUX release (2.5) o The branches that should be exported are currently set in each separate post-update hook, so once a new CRUX version is released, you need to touch {core,opt,contrib,xorg,xfce}.git/hooks/post-update. o More? Opinions? Should we do that switch? I've already written the necessary shell code, it just needs to be put in some separate function that can be sourced from the various hooks. Regards, Tilman -- A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing? A: Top-posting. Q: What is the most annoying thing on usenet and in e-mail?
Hi,
Since we'd switch from "crux-2.4/core" style directories to "core/2.4" or something, we'd have to adjust our *.rsync files. Also we'd need to keep the old rsync area alive for users who are still running old CRUX systems. [...] Disadvantages: o We'd have to adjust the *.rsync files. Would be doable with the CRUX release (2.5)
well, I think that could be also possible with a new core/ports package, which is the owner of the official *.rsync files I can't see more disadvantages
Opinions? Should we do that switch? I've already written the necessary shell code, it just needs to be put in some separate function that can be sourced from the various hooks. I didn't know how git-rsync works on our repos before, so I think having something like: /core/{2.4,2.5,...} /opt/{2.4,2.5,...} ... /xfce/{2.4,2.5,...} ...
is really better than the old one: /2.4/{core,opt, ..., xfce,..} IMHO it sounds a reasonable way to do it +1 Best regards, Jose V Beneyto
participants (2)
-
Jose V Beneyto
-
Tilman Sauerbeck