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