/ Published in: Bash
                    
                                        
A very simple quick way to count the number of files in a directory.
                
                            
                                Expand |
                                Embed | Plain Text
                            
                        
                        Copy this code and paste it in your HTML
ls -1 | wc -l
## You can also use find to search recursively and count the returned files:
find . -name "*.rhtml" | wc -l
Comments
 Subscribe to comments
                    Subscribe to comments
                
                