Creating bulk directories and files on FreeBSD

Introduction

For when you need to bulk create bulk folders and files for testing. The command line to the rescue as always.

Commands

For bulk directories:

mkdir subdir_{0001..1000}

For bulk files within those directories:

find . -type d -exec touch {}/file01 \;

Leave a comment

Your email address will not be published. Comments are moderated before appearing.