cmd calculer le nombres de lignes d'un fichier
La commande "wc -l" retourne le nombre de lignes d'un fichier:
ex:
$ wc -l .bash_history
500 .bash_history
ou:
$ cat .bash_history | wc -l
500
ex:
$ echo "un
> deux
> trois
> quatre
> cinq"
un
deux
trois
quatre
cinq
donc:
$ echo "un
> deux
> trois
> quatre
> cinq" | wc -l
5
ex:
$ wc -l .bash_history
500 .bash_history
ou:
$ cat .bash_history | wc -l
500
ex:
$ echo "un
> deux
> trois
> quatre
> cinq"
un
deux
trois
quatre
cinq
donc:
$ echo "un
> deux
> trois
> quatre
> cinq" | wc -l
5