lundi 6 avril 2020

Displaying the result of two grep commands in bash

I am trying to find the number of files in a directory with two different patterns in the filenames. I don't want the combined count, but display the combined result.

Command 1: find | grep ".coded" | wc -l | Output : 4533

Command 2: find | grep ".read" | wc -l | Output: 654

Output sought: 4533 | 654 in one line

Any suggestions? Thanks!

Aucun commentaire:

Enregistrer un commentaire