Created
August 25, 2014 12:12
-
-
Save davestewart/87ac61a871b3aee4c9be to your computer and use it in GitHub Desktop.
Start Server Apple Script
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
# Starts server in current folder | |
tell application "Finder" | |
set currentDir to POSIX path of ((container of (path to me)) as text) | |
end tell | |
tell application "Terminal" to activate | |
tell application "Terminal" | |
do script ("cd '" & currentDir & "'") | |
do script ("python -m SimpleHTTPServer") in front window | |
end tell | |
tell application "Google Chrome" to open location "http://localhost:8000" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment