[19:42] <nedal_> Bonjour
[19:48] <Ankman> hi
[19:56] <nedal_> Je voulais savoir l utilité de la commande cat 
[19:57] <nedal_> si on tappe cat 'fichier' ça affiche le contenu de fichier sur le terminal 
[19:58] <nedal_> si on tappe cat 'fichier1'  fichier2 ' on liste le contenu des 2 fichiers 
[19:58] <nedal_> mais si on ajoute un > entre les 2 fichier 
[19:59] <nedal_> ça fait copier le contenu du 1er et le colle dans le 2eme on supprimant le contenu original 
[20:07] <Ankman> cat file1 file2 > file3
[20:07] <Ankman> umm...
[20:07] <Ankman> cat file1 file2 >> file3
[20:08] <nedal_> ça fait quoi cette commande ? 
[20:08] <nedal_> c est quoi la diff entre les 2 ? 
[20:11] <Ankman> > fait effacer avant copier
[20:11] <Ankman> >> ajute
[20:12] <nedal_> Je veux savoir aussi, est ce que le Shell et le terminal sont la même chose ? 
[20:12] <Ankman> ajoute (my french is bad, sorry)
[20:13] <Ankman> shell est un logiciel dans un terminal
[20:14] <Ankman> the shell, like bash, sh and others runs insode a terminal
[20:14] <Ankman> inside
[20:15] <nedal_> so shell is what connects the user ( specifically programs) to the kernel 
[20:16] <nedal_> and the terminal is where we can do this 
[20:16] <nedal_> is that correct ? 
[20:16] <Ankman> sheel is an interpreter of commands
[20:17] <Ankman> an environment. like the progamming language Basic
[20:17] <Ankman> from the bash man page: "Bash  is an sh-compatible command language interpreter that executes commands read from the standard input or from a file."
[20:18] <nedal_> and the terminal  does the same thing, no? 
[20:18] <Ankman> bash is mostly used as default shell in linux. you can find out what you run typing "echo $SHELL" (no "")
[20:19] <Ankman> the terminal provides the environment of things, like a shell. draws characters and other things
[20:19] <Ankman> you can eun shell command without a terminal
[20:19] <Ankman> run
[20:21] <Ankman> here from my gnome-terminal (that's just one of hundred terminals) man page: "GNOME Terminal is a terminal emulation application that you can use to perform the following actions:
[20:21] <Ankman> Access a UNIX shell in the GNOME environment.
[20:21] <Ankman> A  shell  is a program that interprets and executes the commands that you type at a command line prompt. When you start GNOME Terminal, the application starts the default shell that is specified in your system account. You can switch to a different shell at any time.
[20:21] <Ankman> Run any application that is designed to run on VT102, VT220, and xterm terminals.[6~
[20:23] <Ankman> a terminal is like a television: it shows things inside (text output usually)
[20:24] <nedal_> it s pretty much clear now, thank you Ankman 
[20:27] <Ankman> :-)
[20:28] <nedal_> please, how can I switch to a different shell 
[20:28] <nedal_> and, is it dangerous ? 
[20:28] <nedal_> because I m a new Linuxien 
[20:29] <nedal_> I used to work on windows
[20:29] <Ankman> you just type the name of the other shell. that opens the new shell in the old shell. like a cascade
[20:30] <Ankman> but the bash shell is the most powerfull. i wouldn't change it
[20:31] <Ankman> windows also has a quite powerfull shell. called cmd
[20:31] <Ankman> if you want to see what bash can, type "man bash". you can scroll up and down with the curser keys. "q" brings you back to the command prompt
[20:32] <nedal_> ah okey !! then the equivalent of cmd is bash !
[20:32] <Ankman> you can do "man" with almost anything on linux. man stands for manual. those are the so called man pages
[20:33] <nedal_> yes I know :)
[20:33] <Ankman> yes, cmd and bash are shells. but different although some command work the same way
[20:33] <Ankman> i don't know if cmd has "pipes". bash and sh have
[20:34] <nedal_> pipes ? what s that ? 
[20:35] <Ankman> it's a | where what is output on the left is used as input for what is on the right. i try to think of an example...
[20:35] <Ankman> do you know "grep"?
[20:37] <nedal_> yes I know grep
[20:37] <Ankman> means "get regular expression pattern" and is a powerfull filter itself. easiest example is "grep nedal_ /etc/passwd" which should list only your user in that file
[20:37] <Ankman> okay
[20:37] <Ankman> another is called "ps" which lists all running processes. now the example...
[20:37] <Ankman> ps axu | grep 100
[20:38] <Ankman> that would list all processes, "pipes" them to grep and grep filters for "100". so only if something has "100" there will be listed
[20:39] <nedal_> ok I see 
[20:39] <Ankman> you can have a lot of pipes. one take the output of the previous
[20:40] <Ankman> like
[20:40] <nedal_> it s like the {} on find command 
[20:40] <Ankman> ps axu | grep 100 | grep root
[20:40] <nedal_> ??
[20:40] <nedal_> kind of
[20:42] <Ankman> i think {} runs the command in there
[20:43] <Ankman> in bash the $() does it
[20:43] <Ankman> or what is inside ``
[20:52] <nedal_> I cant understand very well but i guess it s normal
[20:52] <nedal_> i m a new user of linux 
[20:56] <Ankman> it's called "Command Substitution" and most linux user never go so deep into the shell ;-) i try to find an example
[20:58] <nedal_> before that, do you know the difference between more and less? because I see that both print the contents of the file
[20:59] <Ankman> let's say you have a file called "nedal" which has "ps axu | grep 100" as content
[20:59] <Ankman> then $"(cat nedal)" will do the same as "ps axu | grep 100"
[21:00] <Ankman> more is not so user friendly. you cannot scroll up for example
[21:01] <Ankman> anyway, most linux users never so so deep into it. it very complex and big. but if you want you should get a book or online tutorial
[21:03] <nedal_> i can scroll up with 'b'
[21:03] <nedal_> and scroll down with space
[21:04] <Ankman> in more? oh that i didn't knew
[21:04] <Ankman> ha! :-)
[21:06] <nedal_> :D happy to bring you something new !
[21:07] <Ankman> :-)