I was stripping everything from the last . to the end, then taking the basename. That would have failed, though, on "blah/.local/meow" as it would have stripped it to "blah/", then taken the basename. Now I'm taking the basename of the whole thing, then removing the end.
So, if certain scripts exist, they will be run with the mirror is built. This is something I've wanted for quite a while. There are a series of things I always did as soon as I built a mirror so I could tell it apart and use it and stuff. Now this is all in scripts, so it'll just be done for me. Happy.
This is a change I've been meaning to make for a while now. Now you can build a few mirrors at the same time. In general, though, I've used this opportunity to tighten everything. There's more error checking than there was, it refuses certain things. I've tried to make it "backward compatible" in that if you only ever have one at a time, it will work as it previously did. It does that by picking the only one if there's only one. It also tries to clean up more than it used to. Specifically, if you clean up the last mirror, it should be as though you never had any.