Sunday, May 5, 2024
3
rated 0 times [  3] [ 0]  / answers: 1 / hits: 865  / 2 Years ago, sat, april 9, 2022, 11:38:23

I have a directory that contains around 100 subdirectories. I want to take all the files from this directories and add them to the first directories then delete them all. Is this possible?


More From » command-line

 Answers
3

You can paste a command like this at terminal:



find /source/dir/* -exec mv {} /destination/dir/ ;

[#43860] Monday, April 11, 2022, 2 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
zzlingots

Total Points: 414
Total Questions: 130
Total Answers: 117

Location: Sudan
Member since Tue, Sep 15, 2020
4 Years ago
;