Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Can anyone tell me about the output/purpose of this command?

ls -l | grep gopal | wc -l

share|improve this question

closed as not a real question by Zypher, Massimo, Doug Luxem, AlberT, Chris S Aug 24 '10 at 18:48

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.If this question can be reworded to fit the rules in the help center, please edit the question.

1  
homework? context of question? –  Bart Silverstrim Aug 24 '10 at 18:41

1 Answer 1

It will show the number of files in the current directory which contain the string "gopal" in their name.

Or at least it would, if it had been written correctly...

share|improve this answer
    
What's wrong with it? Seems fine to me –  James Lawrie Aug 24 '10 at 18:42
1  
Or possibly files owned by user/group "gopal" –  jscott Aug 24 '10 at 18:45
    
good point, so ls -1 would probably be better than ls -l –  James Lawrie Aug 24 '10 at 18:47
    
@James: it wasn't fine when first posted. –  Massimo Aug 24 '10 at 20:07

Not the answer you're looking for? Browse other questions tagged or ask your own question.