Skip to content

workspace open: --no-checkout doesn't need --force

Remove the requirement to specify '--force' in conjunction with '--no-checkout' if there are already files in the workspace. We won't write anything when opening the workspace, so there's nothing to force.

For example, when opening a workspace to an existing clone of a repository, it seems alarming to have to '--force' the workspace open. It made me wonder if it will actually be overwritten.

I tested all the combinations of {,--no-checkout} x {,--force} x {"with empty dir", "with full dir"}.

The combination "with full dir" fails, as expected.

Perhaps there's separate work to be done in the --force, "with full dir" case, as it failed to overwrite the existing files. That's not related to this change though.

Merge request reports

Loading