You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
mv -f switch highly desired, so as to not overwrite files by default #6747
Basically, mv in this shell currently seems to act like mv -f in other shells, which seems unusually dangerous for a program intended to be interacted with by humans. Basically, I think the -f (--force) switch should be added to mv for cases of overwriting.
Here's an example of something I was writing that would rename a bunch of images to just sequential numbers. See if you can spot the massive data loss problem that a -f switch would probably have prevented.
ls | sort-by modified | get name | each -n {|e| mv $e.item ($e.index + 1 | into string | $in + '.jpg' )};
Activity
fix: ✨ "saner" default for mv
Make default for mv safer, require `-f` to overwrite (#6904)