I have -


I want -

  |   |--LaTeX_wikibook.pdf  
  |   |--LaTex_advanced.pdf
  |   |--vimLaTeX.pdf

I want to move only those file having substring LaTeX to the folder LaTeX. How can I do this in one command?

  • Did you try something like mv *LaTeX*.* LaTeX/? Sorry, on my phone, so can't test. – ThatGuy Jul 18 '17 at 14:12

Like this ...

cd Books/
mv *LaTeX*.pdf LateX/

You can exchange the "pdf" for a "*" to if you have other extensions.

  • I think you missed the capitalization in LaTeX/ :) – ThatGuy Jul 18 '17 at 14:18
  • 1
    Hmmm? Where? >:-D – Rinzwind Jul 18 '17 at 14:19
  • 1
    You wrote mv *LaTeX*.pdf LateX/, it should be mv *LaTeX*.pdf LaTeX/. Hehe – ThatGuy Jul 18 '17 at 14:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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