Showing posts with label ls command. Show all posts
Showing posts with label ls command. Show all posts

28 April 2013

Some LS Command Practical Examples

66 comments


ls command is one of the most frequently used command during a Linux Session. Here are some ls command practical examples to make your Linux Command line experience more enjoyable and faster. Iam assuming that you know basic ls usage like ls -l, ls -a, ls -R etc.


Trick 1:

List Only directories in a Current Directory using ls -d */

$ ls -d */
bootstrap/        Documents/     Music/      sandeep/      VirtualBox VMs/

Trick 2:

List Only hidden directories in a Current Directory using ls -d .*/

$ ls -d .*/
./             .gimp-2.8/          .mplayer/          .ssh/ 
../            .gnome2/            .mysql/            .subversion/ 
.adobe/        .gnome2_private/    .nbi/              .swt/ 
Read More...