When using the -i option with the mv command, the interactive prompt appears when you attempt to move a file to a destination where a file with the same name already exists.
Example Command:
mv -i file.txt destination/
Interactive Prompt:
If destination/file.txt already exists, you will see a prompt like this:
mv: overwrite 'destination/file.txt'?
User Response:
At this point, you can respond with:
y: to confirm and overwrite the existing file.n: to cancel the move operation.
This prompt helps prevent accidental data loss by requiring your explicit confirmation before overwriting files.
