The actual problem is one of power and intention. Yes, version control would make earmarks obvious. Yes, it would make tracking contributors (lobbies) easier. Yes, it would make tailoring tried and trusted legal documents easy.
All of these are reasons why version control will never be applied to the law. We want these things, but we are not the customer. The real customer is actively trying to prevent these things from ever happening.
The reality is that these tools are probably already being used for these exact purposes - in private, and for personal gain.
/rant
Continuing with OP's thought. Making the legislator who introduces the bill commit the bill would be an awesome piece of information and might make some legislators think twice about what they introduce and how they title it. And all the statistics that could be run on a repo of laws would be a ridiculously useful resource.