0

I have a question regarding directories. My homework question is this:

Use metacharacters and the ls -lL command (with lower and upper case L) to list all filenames under the datafiles directory that contain a dot '.' with the letter 'f' or 'u' anywhere after the dot.

I know it begins ls -lL, but I'm not sure what else to put.

closed as unclear what you're asking by Jeff Schaller, αғsнιη, G-Man, jayhendren, Isaac Feb 9 '18 at 2:34

Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.

  • 1
    You can read the man page of ls, just type in your prompt man ls, there you can read about your homework. Just a tip: I think that the option your are looking for is ls -ILa . Greetings – k.Cyborg Feb 7 '18 at 16:11
  • Can you point us to your most recent class/lab material? Hopefully we can point out what you've missed. – Jeff Schaller Feb 7 '18 at 16:20
  • Don't forget to hit our tour page after registering your account, so that you can edit your question and accept answer(s)! – Jeff Schaller Feb 7 '18 at 16:34
  • Does u or f can appear untill a first dot seen? Like u.file..f what about Hidden files? .a hidden file – αғsнιη Feb 7 '18 at 16:58
  • @k.Cyborg: I believe that you’re sending the OP on a wild goose chase.  The answer to this question cannot be found in the ls man page. Hint: if you learned about ls on Monday, you should look closely at your notes from last Thursday and Friday, and Tuesday. – Scott Feb 7 '18 at 18:14
2

filenames under the datafiles directory that contain a dot '.' with the letter 'f' or 'u' anywhere after the dot.

If I was to guess, it'd be something like:

ls -lL datafiles/*.*[fu]*

although the datafiles directory could be anywhere (else), and I find it a little odd that they're encouraging habitual use of the -L flag.

  • 2
    I personally can't remember the last time I used -L with ls... – Kusalananda Feb 7 '18 at 16:38

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