Top "Ls" questions

A utility in Unix-like systems such as Linux used for listing files and directories.

Linux delete file with size 0

How do I delete a certain file in linux if its size is 0. I want to execute this in an …

linux filesystems delete-file ls rm
How do I list one filename per output line in Linux?

I'm using ls -a command to get the file names in a directory, but the output is in a single …

linux shell ls
To show only file name without the entire directory path

ls /home/user/new/*.txt prints all txt files in that directory. However it prints the output as follows: [me@…

shell unix directory ls
How to create ls in windows command prompt?

I want to use ls in windows command prompt and make it run the dir command. How can I do …

windows windows-xp cmd ls dir
List of All Folders and Sub-folders

In Linux, I want to find out all Folder/Sub-folder name and redirect to text file I tried ls -alR &…

linux ls
Unix ls command: show full path when using options

I often use this list command in Unix (AIX / KSH): ls -Artl It displays the files as this: -rw-r--r-- 1 myuser …

shell unix command-line ls
How do I assign ls to an array in Linux Bash?

array=${ls -d */} echo ${array[@]} I have three directories: ww ee qq. I want them in an array and then …

arrays bash shell ls
'ls' is not recognized as an internal or external command, operable program or batch file

'ls' is not recognized as an internal or external command, operable program or batch file. I get this error when …

batch-file cmd command ls
Regular Expression usage with ls

I am trying to use ER (Extended Regular Expressions) with ls like ls .+\..+. I am trying to print all files …

regex ls glob
Using grep and ls -a commands

Using an ls –a and grep, how would you list the name of all of the files in /usr starting …

linux unix grep command ls