💻 Software
scp -r ... but leave out (exclude) a specified subdirectory
Fresh7 days ago
Mar 15, 202664657 viewsConfidence Score0%
0%
Problem
Here's the directory structure: I want to copy everything, EXCEPT for the /a/c/ subdirectory. Q: How would I specify a directory to leave out in the scp command ?
Error Output
/a/ /a/b/ /a/c/
Unverified for your environment
Select your OS to check compatibility.
1 Fix
Canonical Fix
Unverified Fix
New Fix – Awaiting Verification
Fix for: scp -r ... but leave out (exclude) a specified subdirectory
Low Risk
I don't think you can, but you could use rsync? Something like this:
Awaiting Verification
Be the first to verify this fix
Sign in to verify this fix