[Linux]How to get top directories/files based on disk usage

Getting the top disk usage files/directories is a common use case and we need to often use it to find them out. Here is a handy tip on how to find top 10 directories/files based on the disk usage Here is the syntax

Here we replace base folder to the location where we want […]

Continue reading

How to read user input in bash script

Many times we need to provide user input to the bash script to take actions accordingly. We can use bash builtin “read” command for same. Let’s see a quick example

  As we see we are reading input to a runtime variable named as “XYZ”. We can use value of the variable anywhere in […]

Continue reading