I have multiple files in multiple directories some buried under subdirectories. I want to be able to move all files until they are only 1 directory deep.
for example:
/home/folder/subfolder/file1.txt
/home/folder2/file2.txt
/home/folder3/subfolder/subfolder/subfolder/file3.txt
becomes:
/home/folder/file1.txt
/home/folder2/file2.txt
/home/folder3/file3.txt
I found that I can use
find ./*/ -type f
to locate all the files. But I'm not sure how to move them so that they are only 1 directory deep.