Operating Systems > Linux and UNIX

Possibly useful commands

<< < (3/4) > >>

toadlife:

--- Quote from: H_TeXMeX_H ---Well ... no ... It was kinda hard to find them too, mostly by chance. Besides, the documentation I've found isn't too clear anyway. Oh, I forgot to tell you, I hate reading manuals. And where would you find Ctrl Alt F1 ? I found it while trying to install the non-free nvidia drivers manually.
--- End quote ---

Well I guess this just shows how out of touch I am with current linux distros.  IN BSD, you don't survive very long without knowing most of those commands.

When you have to set up your X with the old-syle Xorgconfig program and then tweak it manualy afterward and then set up your .xinitrc file by hand just to get your desktop manager to load, you tend to pick up these things quickly.

H_TeXMeX_H:
Advanced Bash-Scripting Guide

useful in Linux administration

Calum:

--- Quote ---$ cat file1 file2 file3 ... fileN > concatenatedfile
--- End quote ---
i am probably being really dumb, but shouldn't it be >> rather than > ?

i am under the impression that > wipes the existing contents of the outfile, if it exists, while >> appends the inputs to the outfile. is this wrong?

piratePenguin:

--- Quote from: Calum ---i am probably being really dumb, but shouldn't it be >> rather than > ?
--- End quote ---
It doesn't need to be >> because 'cat file1 file2...' will concatenate file1 and file 2 to stdout, redirect that to overwrite concatenatedfile with >. You could use >> if you want whatever's already in concatenatedfile to stay.

--- Quote ---
i am under the impression that > wipes the existing contents of the outfile, if it exists, while >> appends the inputs to the outfile. is this wrong?
--- End quote ---
No, correct.

Aloone_Jonez:
I haven't tried it on UNIX but that's certainly the case for DOS which stole piping from UNIX, so I agree.

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version