Phillip Wood <phillip.wood123@xxxxxxxxx> writes: >> Although my test case uses EOL normalization, I think the real issue is >> that autostashing for the rebase fails (in the sense that the working >> tree is clean afterwards) and that is unexpected. > > Yes. I'm not sure what to do for the best. A simple fix to the stash > failure is to check for a clean worktree after we've stashed and apply > the stash and exit if the worktree is not clean. The suggested fix covers all cases where the auto-stash step fails to revert the index and the working tree to the prestine state for any reason, not limited to the eol normalization. It is not just a simple but necessary fix, regardless of what other things we do. Why doesn't the internal "stash" fail to clean the index and the working tree to pristine state in the first place, though? It may be another thing that needs fixing, but in a sense, that is of secondary importance. Thanks.