-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #6 from terrabyte-tech/dev
dev: update localserve micro-opt version
- Loading branch information
Showing
2 changed files
with
31 additions
and
6 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
@ECHO OFF | ||
:: v2.0 | ||
:: to execute as expected, requires python 3.x | ||
|
||
:start | ||
set choice= | ||
set /p choice= Open browser to view served website? [N]: | ||
if not '%choice%'=='' set choice=%choice:~0,1% | ||
if '%choice%'=='Y' goto yes | ||
if '%choice%'=='y' goto yes | ||
if '%choice%'=='N' goto no | ||
IF '%choice%'=='n' goto no | ||
if '%choice%'=='' goto no | ||
echo "%choice%" is not valid | ||
echo. | ||
goto start | ||
|
||
:no | ||
echo Skipped... | ||
clear | ||
GOTO | ||
|
||
:yes | ||
echo Opening browser... | ||
start "" http://localhost:8000 | ||
|
||
:startServer | ||
ECHO starting local server at | ||
ECHO %cd% | ||
ECHO with python (localhost:8000) | ||
python -m http.server |