Share your knowledge at the LQ Wiki.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 08-25-2008, 11:23 PM   #16
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910Reputation: 910

Originally Posted by CoffeeKing!!! View Post
I've used tee to copy files. I just have to manually enter the file numbers myself.

me@me:~/Desktop$ cp | tee

and I get:

cp: missing destination file operand after `'
Try `cp --help' for more information.

The files show up but, I get that error. Does anyone know why?
I'm looking for something similar to similar to tee or cp so I don't stray to far from novice commands for now.
And the problem there is that cp requires two parameters;
to "copy" using tee you just want to cat the file.
cat | tee
What you would have gotten (in verbose mode) if you hadn't
omitted the target to copy is the output of the successful
copy command in three separate files.

Old 08-26-2008, 02:44 PM   #17
Registered: Mar 2008
Posts: 117

Original Poster
Rep: Reputation: Disabled
Thanks for the help guys. I'll throw this in when I get to the scripting part of the book I'm reading.
Old 09-06-2013, 06:41 AM   #18
LQ Newbie
Registered: Oct 2011
Posts: 1

Rep: Reputation: Disabled
Interesting finding

Hi all,

This thread is old. Hope any one can see my reply.
You can use following command:
cat copy_file |tee file_name{1..5}
It will out filename1 filename2, filename3, filename4, filename5.
Hope this is the results you want.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
My error in mkisofs command to make a command line iso mg92865 Linux - Newbie 1 06-20-2008 11:43 AM
[SOLVED] How can I make an .iso file from a CD or DVD using the command line? rm_-rf_windows Linux - General 3 06-20-2007 08:29 AM
Multiple Command-Line Programs skibud2 Linux - Software 1 03-18-2007 06:17 PM
Command to output file content line by line aznluvsmc Programming 2 09-12-2004 07:45 PM
Multiple tty in command line tearinox Linux - General 2 02-12-2004 10:28 AM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 06:42 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration