Linux cp command to copy a folder to current directory

Just omit the -T parameter, as that’s what prevents the command from working properly:

cp -r /home/hope/subfolder .

The -T parameter treats the target argument as a file, so no copying will be performed at all if that is actually a directory.

A friendly reminder: virtually all Unix commands have a –help command line argument that is worth trying out in case of a trouble 🙂

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)