Update the lockfile when deps are modified

Closes #314
auto merge of #323 : alexcrichton/cargo/issue-314, r=wycats

Closes #314