Patch based on the one by David, also has blackbox tests.
I think this is not the right solution though, it's the update logic that needs to be fixed. The lightweight checkout case is especially tricky, as you can't require a local commit first because you don't have those for a lightweight.
Patch based on the one by David, also has blackbox tests.
I think this is not the right solution though, it's the update logic that needs to be fixed. The lightweight checkout case is especially tricky, as you can't require a local commit first because you don't have those for a lightweight.