September 26, 2010

can you copy two files at the same time to a directory using just one command to do this

There are multiplse ways to accomplish this by the simplest is by using the...

There are multiplse ways to accomplish this by the simplest is by using the sample script that goineasy9 has given.

If you wish to use more dynamic or network based functions your should look into xargs, find, rsync and scp.

Like  (5 likes)

There are multiplse ways to accomplish this by the simplest is by using the...

There are multiplse ways to accomplish this by the simplest is by using the sample script that goineasy9 has given.

If you wish to use more dynamic or network based functions your should look into xargs, find, rsync and scp.

Like  (5 likes)

There are multiplse ways to accomplish this by the simplest is by using the...

There are multiplse ways to accomplish this by the simplest is by using the sample script that goineasy9 has given.

If you wish to use more dynamic or network based functions your should look into xargs, find, rsync and scp.

Like  (5 likes)

Or, if you have more than one to copy at a time, you can try tools like rsync...

Or, if you have more than one to copy at a time, you can try tools like rsync and cpio.

Also, if the files in question have similar attributes, you can use something like 'find' with the -exec argument like:

find /path/to/old/dir -name "file1" -o -name "file2" -exec cp {} /path/to/new/dir \;

Like  (1 like)

if you literally mean "at the same time" you can use parallel - its a very...

if you literally mean "at the same time" you can use parallel - its a very usefull tool which provides you with ability to paralelize execution of several task or to execute a complex task in parallely. In you situation it would look something like this:

ls * | parallel --jobs +4 'cp {} /some_dir'

which means that parallel will take create 4 threads and every of them will try to copy one file piped from "ls" command

Like  (1 like)

type "man copy" into a terminal, and you can see how it works....

type "man copy" into a terminal, and you can see how it works.

cp filename1 filename2 /somedirectory

Like  (1 like)
Click Here!