Created
October 13, 2013 17:55
-
-
Save devdrops/6965214 to your computer and use it in GitHub Desktop.
File created to implement a loop structure in a bat file to create a basic folder structure while the user still wants to create it.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@echo off | |
color 0A | |
title Window Title Goes Here! | |
cls | |
:start | |
echo. | |
echo ************************************ | |
echo * BAT FILE TO CREATE STRUCTURES * | |
echo ************************************ | |
echo. | |
echo Welcome, %USERNAME% :) | |
:options | |
echo. | |
echo. | |
echo. | |
echo. | |
echo What would you like to do? | |
echo. | |
echo 1. Start a project (Base Structure Folder) | |
echo 2. Create a Module (Module Structure Folder) | |
echo. | |
echo 0. Close program | |
echo. | |
set /p choice="Enter your choice: " | |
if "%choice%"=="1" goto project | |
if "%choice%"=="2" goto module | |
if "%choice%"=="0" goto finish | |
:project | |
echo. | |
echo Starting a project, on the go! | |
echo. | |
set /p name="Project name: " | |
set /p path="Project path: " | |
echo. | |
echo Creating "%name%" into "%path%" ... | |
echo. | |
echo Done! | |
goto options | |
:module | |
echo. | |
echo Creating a new Module. | |
echo. | |
set /p name="Module name: " | |
echo. | |
echo Creating module "%name%" into "modules/%name%" ... | |
echo. | |
echo Done! | |
echo. | |
set /p confirm="Create a new Module? (Y/N): " | |
if "%confirm%"=="Y" goto module | |
goto options | |
:finish | |
echo. | |
echo "Work complete!" - Orc Peon | |
pause |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment