Linux - GeneralThis Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
The manual page shows the basic usage of cat; you could also check the manual page for bash and scroll to the section titled "Here Documents" for some slightly more complex usages.
cat is short for "concatenate", and is often used to read files, like:
shell$ cat filename # this will read the file "filename" to the screen.
For the manual, type:
shell$ man cat
Or, if there's some particular usage case that you are not understanding, please post us an example, or provide more detail of exactly what you wish to know about cat.
Sasha
PS - you should create a more informative title for your thread(s) -- an example would be:
"Please tell me about the `cat` command-- how to use it?"
You can edit this thread title by clicking EDIT, then click GO-ADVANCED, and fix up the title
Cheers!
Last edited by GrapefruiTgirl; 09-20-2009 at 09:56 PM.
The manual page shows the basic usage of cat; you could also check the manual page for bash and scroll to the section titled "Here Documents" for some slightly more complex usages.
cat is short for "concatenate", and is often used to read files, like:
shell$ cat filename # this will read the file "filename" to the screen.
For the manual, type:
shell$ man cat
Or, if there's some particular usage case that you are not understanding, please post us an example, or provide more detail of exactly what you wish to know about cat.
Sasha
PS - you should create a more informative title for your thread(s) -- an example would be:
"Please tell me about the `cat` command-- how to use it?"
You can edit this thread title by clicking EDIT, then click GO-ADVANCED, and fix up the title
Cheers!
Is this the way to reply??? I'm still trying to find out how to use this site. If so:
need to join 2 avi files, man pages deal only in text files. (??) and the example does not work for me,
echo the content of file1 and the content of file2 on stdout :
Code:
cat file1 file2
Quote:
I need to join 2 avi files. cat man instructions deal with text files, and don't seen to work on avi files.
cat works fine, but don't expect to have a nice avi file when concatenating two of them. Chances are they are out of sync (think of the headers etc).
From http://linuxclues.blogspot.com/2008/...avi-files.html, to join two avi files with mencoder :
Is this the way to reply??? I'm still trying to find out how to use this site. If so:
need to join 2 avi files, man pages deal only in text files. (??) and the example does not work for me,
Yes, that's a pretty good way to reply, I thought.
And it was effective: it caused you to provide more detail about what exactly you're trying to do, AND it educated you about an aspect of using this site
The real answer is that it all depends on the file type. Some formats like mp3 have an atomic structure, where each individual subsegment contains all the playback information necessary for that segment. This kind of format can be easily combined by cat without affecting playback ability (though you may have issues with things like metadata tags).
But AFAIK the avi container isn't one of those. It uses a single header at the beginning of the file to define the playback parameters for the whole file. You generally have to rebuild the whole container if you edit the media inside it. This means you need to use a dedicated video editor, such as mencoder or ffmpeg.
O.K. Now I've posted a dum question, gotten very good answers, so now how do I respond to whomever has been kind enough to provide me with the needed help, or "yep, I tried that, didn't work" response. ?? Is this block the correct place for this?? Or: Where's the operating manual for navigasting this site?
echo the content of file1 and the content of file2 on stdout :
Code:
cat file1 file2
cat works fine, but don't expect to have a nice avi file when concatenating two of them. Chances are they are out of sync (think of the headers etc).
From http://linuxclues.blogspot.com/2008/...avi-files.html, to join two avi files with mencoder :
Is this the spot for answering a particular person who has offered help? If so: thanks, I got mencoder installed, (I think) but when I tried to use it per instructions I got the "command not found " message.
is reboot required?
how do I respond to whomever has been kind enough to provide me with the needed help
David the H. has in his signature :
Quote:
And when you get an answer:
a) Post a follow-up comment letting people know it worked.
b) Thank those who've helped you (click the thumb icon).
c) Mark the thread as "solved" (located in the "thread tools).
Just keep posting in th thread unless you feel the topic has changed so much athat a new thread is approriate. In this case you started asking about cat and it looks like the topic is changing to mencoder and ffmpeg.
Regards an LQ user guide I don't know of one. Just by lurking you'll see how things are done and the regular posters are pretty friendly and will keep you pointed in the right direction. Relax. Enjoy
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.