On Mon 07 Feb 2011 18:56 +0100, Lukas Fleischer wrote: > On Mon, Feb 07, 2011 at 06:50:14PM +0100, Lukas Fleischer wrote: > > > Blacklist helper side: > > > * I won't lie, I think this is over-engineered a tad. This can be done > > > in a much shorter and easier to hack shell script since all you need > > > is package names- just pipe bsdtar output through some magic and you > > > have package names. I've attached a sample starter script I use for > > > archweb updates. I'd probably have it call bsdtar and then who knows > > > what. > > > > Our consensus was not to fetch tarballs via HTTP and extract them here, > > but use libalpm instead. We already discussed using a small PHP script > > that uses Archive::Tar (PEAR) but discarded that. Using libalpm, future > > database format changes won't affect us and it just seems cleaner. > > > > Of course, we could do that with some shell script which would have to > > do following things tho: > > > > - parse the AUR "config.inc" file: read MySQL host name, socket, user > > name, password > > - use pacman(8) to sync local databases > > - convert packages to MySQL queries using some sed(1)/awk(1) magic > > - pipe stuff to mysql(1), ensure no errors occurred > > > > I just think that it wouldn't be much shorter (that C helper has about > > 100 SLOC if you strip all that error handling stuff), nor cleaner, nor > > faster. Best thing would to have PHP bindings for libalpm here... Well. > > Recommendations and patches welcome :p > > Oh, and I'll probably make this script add package names listed in > packages' "provides" arrays to the blacklist as well (thanks to Justin > Davis, just read his reply).
Awesome :D. Rather than creating another config file, would it be possible to just point to the AUR's config.inc? Maybe a PHP wrapper around aurblup... Kind of like the cleanup script? (That script should probably be changed to point directly to the config file.) Also I found a couple typos: something about dwm, and leightweight. Thanks Lukas, you're the new hero of the AUR. :D