undo git clean -fdx code example Example 1: how to undo git clean -fd command git clean -fdx Example 2: how to undo git clean -fd command git clean -fdxn