linux command to get size of files and directories present in a particular folder?

Use ls command for files and du command for directories. Checking File Sizes ls command will not list the actual size of directories(why?). Therefore, we use du for this purpose. Checking Directory sizes Including -h option in any of the above commands (for Ex: ls -lh * or du -sh) will give you size in human readable format (kb, mb,gb, …) For more information see man ls and man du

Looping through the content of a file in Bash

One way to do it is: As pointed out in the comments, this has the side effects of trimming leading whitespace, interpreting backslash sequences, and skipping the last line if it’s missing a terminating linefeed. If these are concerns, you can do: Exceptionally, if the loop body may read from standard input, you can open the … Read more

What does it mean to mount a file system in linux?

A better way to describe “mount” is “attach”. The filesystem being mounted is attached to an empty directory of the existing filesystem. That is, the top level directory of the mounted filesystem becomes the directory on the existing filesystem. Subdirectories of the mounted filesystem become the subdirectories of the former directory on the existing filesystem, … Read more

Using GNU Scientific Library (GSL) under Windows x64 with MinGW

When you build projects for MinGW, under MSYS, you should always specify a –prefix argument to ./configure; (the /usr/local default specifies an MSYS specific path, which is entirely unsuitable for MinGW application development). In your case, you should have configured GSL thus: or, better still, segregate the build files from the sources, (e.g. as a subdirectory of the GSL top source directory): … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)