I want to copy git.sh to ever file below /root
Then I use this
mv git.sh /root/
mv git.sh /root/*
mv moves files. When file in destination exists, it will be replaced. The right command to copy file is
cp. It's used same way as
mv git.sh /root/* will substitute wildcard char
* with all names the directory contains. Then there are a few cases:
mv will remove source but
cp keeps it.
It's better to have destination path with filename, for example
mv git.sh /root/git.sh. When moving multiple files use destination path just to directory without filename or wildcard chars, for example
mv dir/* /root/. When you want to move directory with subdirectories add
man mv or
man cp for more information.