answersLogoWhite

0


Best Answer

I suppose the easiest way to do that would be to use ls and pipe it to word count

ls | wc -l

the -l switch is for number of Lines

for all files, including hidden files (ie .xfce4) use

ls -a | wc -l

hope i could help

User Avatar

Wiki User

14y ago
This answer is:
User Avatar
More answers
User Avatar

Wiki User

11y ago

To list the count of files in Linux use the ls command piped into the wc command as shown below.

ls -l | wc -l

You can also add the grep command to find a more exact count of the files you wish to count as shown below.

ls -l | grep ^a | wc -l

This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: How do you count how many files are in a folder in Linux machine?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

Why is Linux said to be a virus-free operating system?

Ya Linux is virus free OS, How?? Answer: Linux OS Extracted files and folders are kept hidden which cannot be accessed by viruses. Now what are Viruses?? Viruses are the files which carry the path-name of the WINDOWS FOLDER present in Windows OS where all the functional .(DOT)dll files are stored. Once these .dll files get corrupted then the PC starts behaving like a mad bull. So, these .dll kind (not the same format files) of files are also their in Linux OS but they are kept hidden, as a result the virus path cannot find them. Thus, no damage but still the files stored by the user on a Linux machine get corrupted.


You are configuring Windows XP on your machine Which folder properties can you set in Folder Options?

Opening files using a single click Opening folders in the same window Viewing web content in folder


in what folder are driver files stored?

In what folder are driver files stored?


When copying files the folder containing the files to be copied is called the folder?

Source


When copying files the folder containing the files to be copied is called the folder.?

Source


Where is the setup files folder located on your computer?

The set up files folder on the computer can be found on the desktop. Any folder in the All Files section can be synced into this folder.


Can excel files and word files be saved in the same folder?

Yes - I have a folder at home that has both in


How do you delete a lot of files quicker?

Easy...You make a folder (call it something/ or anything) put this folder in the beginning...Name it something (i.e. Deleted files)Drag all your unwanted files (this works best when you have a lot of unwanted files) to your folderOnce that process is complete, you delete the folder*The folder will be deleted, including your unwanted files that you have put in that folder.


A container that holds files and computer programs is called?

A folder


In what folder to you install a program?

That would be the "Program Files" folder. It is usually on C: drive. With a 64 bit system you will have a "Program Files" folder, and a "(x86) Program files" folder. The program itself will usually be in a separate folder in the "Program file" folder. It will either have the name of the program or the name of the program Company. If the folder is named after the company then the program will be in a separate folder inside the company folder.


How do you save folder with password in Linux os 2010?

"Linux OS 2010" doesn't exist. The closest thing to a "folder with a pass word" in Linux is using something like EncFS. encfs encrypted decrypted Provide a passphrase when prompted. Then move the files you to keep encrypted to decrypted, and then unmount it with fusermount -u decrypted. To open it again, you run the first command again and supply the passphrase you gave the first time.


How can i make rtf files into human readable words with my mac os x leopard machine?

TextEdit located in your Applications folder will open and display Rich Text Format (RTF) files.