Create Directories from Textfile

I have a text file named checklog.txt. I want to create directories from that names in the text file line by line.

1 Answer

cat checklog.txt | xargs -L 1 mkdir

Worked for me.

2

Your Answer

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

David Miller

David Miller

Executive Financial & Market Analyst

David Miller brings 15 years of experience in global economics, personal finance strategy, and market dynamics. He specializes in turning complex economic trends into actionable insights for everyday readers.

Share this article
Twitter Facebook Pinterest