package loaders: write extrinsic metadata to directories instead of revisions.
They are more useful on directories, as directory ids are more intrinsic than
synthetic revision ids.
And this adds the revision swhid in the context, so the revision relationship
is still available when it's useful (eg. because the same directory can be
referenced from multiple revisions).