wc -l filename It will return no of lines in the provided file. wc stands for word count.
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
You don't need a script, just use the 'wc' command: # Lines wc -l <file> # Words wc -w <file>
Use the 'ls' command with the long listing option: ls -l
find -type f | wc -l
Type the following command# ls -l
wc is used to count the characters/words/lines in a file or files. You might use it to see how productive you've been (did you finish that 5000 word essay you were supposed to write) or to see how productive some one else has been... The options control characters/words/lines: with no options it gives all three: $ wc notes 56 219 1607 notes There are 56 lines, 219 words, 1607 characters. $ wc -l notes 56 notes I just wanted to know how many lines.
The 'uptime' command will tell you exactly how many users are on the system. There are other variations of this, including counting the number of words from the 'users' command, etc., but this is the easiest.
the "ls" command gives a listing of all the files in the current working directory, "ls" with the -l option gives the listing in vertical format along with file permissions, owner, group, and date when it was last modified. To see a more detailed explanation of the "ls" command and all its options run the command "man ls", man will also work with any other standard Unix/Linux command to give a detailed explanation of its purpose and various options.
PS -e|cut -d " " -fname|wc -l
Use the 'ls' command with the '-l' (long listing) option
Use the 'ls' command with the '-l' (long listing) option
$ ls -l temp