A
A
anriko2021-07-09 10:09:34
SSH
anriko, 2021-07-09 10:09:34

How to recursively copy a directory to folders?

like here only not for the file of the entire folder

find ~ -type d -name 'public_html' -exec cp ~/optimaservis.ru/public_html/yamochnyi-remont/index.php {} \;
или как тут 
find ./*/public_html/fonari-signalnye/  -name ".main-section_adaptive.menu.php" | xargs -n 1 cp ~/mtest/public_html/fonari-signalnye/.main-section_adaptive.menu.php

Answer the question

In order to leave comments, you need to log in

1 answer(s)
H
hint000, 2021-07-09
@hint000

find ~ -type d -name 'public_html' -exec cp -r ~/optimaservis.ru/public_html/yamochnyi-remont {} \;

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question