Skip to content

Instantly share code, notes, and snippets.

@maptastik
Last active May 15, 2025 13:52
Show Gist options
  • Save maptastik/0b8bc37e40f9e80d71c91583f5068d99 to your computer and use it in GitHub Desktop.
Save maptastik/0b8bc37e40f9e80d71c91583f5068d99 to your computer and use it in GitHub Desktop.
A Windows command line tool that creates all the folders and documents to get started with a basic data project.

Installation

  1. Place the file data-project-init.bat in a folder on your machine.
  2. If the folder where you placed the file is not in your user or system PATH, add it.

Run

You can call the script using the full file path. For example:

C:\Users\some-user\data-project-init.bat

If the directory where you saved the script is in your user or system PATH, you can call the script by name:

data-project-init

Parameters

parent_dir: This is the directory where your project directory will be created. It is the parent directory of the project.

project: The name of your project. The script will create a new folder in parent_dir with the value provided for the project name and then add the scaffold of folders for the project within that folder.

Notes

Usually if you have a file path where there are directories with spaces, you have to wrap that path in double quotes. In this case you don't want to do that. This script isn't complicated enough to be able to figure all that out. Just leave the file path without quotes and go on your way.

@echo off
set /p parent_dir="Enter directory where project will be initialized: "
set /p project="Enter project name: "
mkdir "%parent_dir%\%project%"
mkdir "%parent_dir%\%project%\DATA\"
mkdir "%parent_dir%\%project%\DATA\00_RAW\"
mkdir "%parent_dir%\%project%\DATA\01_INTERMEDIATE\"
mkdir "%parent_dir%\%project%\DATA\02_FINAL\"
mkdir "%parent_dir%\%project%\DOCUMENTS\"
mkdir "%parent_dir%\%project%\EXPORTS\"
mkdir "%parent_dir%\%project%\IMAGES\"
mkdir "%parent_dir%\%project%\SCRIPTS\"
mkdir "%parent_dir%\%project%\TEMP\"
echo "# %project%">"%parent_dir%\%project%\README.md"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment