How to access files in subdirectories?

前端 未结 1 736
伪装坚强ぢ
伪装坚强ぢ 2021-01-26 02:21

I have several subdirectories beneath in a main directory, and each subdirectory contains one or two text files. I need to copy these text files to another directory.

H

相关标签:
1条回答
  • 2021-01-26 02:50

    This is simple in a one-line Perl program

    perl -MFile::Copy=copy -e'copy($_, "/d/work/abcd") for </d/work/abc/*/*.txt>'
    
    0 讨论(0)
提交回复
热议问题