Add file.copy, fixes #6440
Merge pull request #6446 from techhat/filecopy

Add file.copy, fixes #6440