In this lecture We'll talk about how to count for size using our program.
I will switch to eat this directory as there are many files I can print the content of directory using
ls l command record files are starting with Desch in the first column.
Things are starting with our character and directories starting with letter D.
So leakin using that.
No separate files from links and directories.
So now let's print only file I was using.
Command C'mon.
So in our search pattern we will use a regular expression for starting with Desch
and we see only regler files listed here.
Great
now we would like to display files of specific extension so we are using pipe up out both of our previous
command as an input into another awk program that will search for files ending with extension dot com.
Don't forget to use backslash before dot revise dot would be represented as any character and not as
edit and visi only files with conflict engine.
Now try to use some extension which doesn't exist.
We don't see an output printed but vote is an exit status
it is zero even awk.
Didn't find anything.
But in our script it would be good to know according to exit status if some extension was found or not
for that reason we can use grep command.
So just rename and remove slushes
we don't see any output printed and exit status.
Is it this number one good.
So that means that if grep didn't find bottom biddable exit with a non-zero status.
Now just for being sure let's search using gap for extension that exists.
And now check exits tattles.
Now it is zero.
Great.
So using grep.
If he can tell if extension exists or not in specific location.