Score:0

How to copy multiple files to a new folder in a new path in one command?

cz flag
Min

[These are the files I want to copy over][1]

Example command I have tried but does not work:

cp permanent_waiver_* /existingpath/newfolder1/newfolder2

This would give me error like no such file or directory.

Nmath avatar
ng flag
You should give us the actual command that you are using and more importantly, the complete and unredacted error. Please use monospace formatting by using backticks so that we can parse the information as it would appear in your terminal. Adding additional formatting and punctuation only adds ambiguity. Also, can you tell us if the source and destination directories actually exist? If you start a path with `/` it is an absolute path and I doubt that `/existingpath` exists on your system
Score:0
cn flag

You have to create your new folder structure first, but this shouldn't be hard.

mkdir -p /existingpath/newfolder1/newfolder2

cp permanent_waiver_* /existingpath/newfolder1/newfolder2

So, it's really two commands.

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.