diff --git a/modules/utility/init.zsh b/modules/utility/init.zsh index 5f7cffb9..3efd784e 100644 --- a/modules/utility/init.zsh +++ b/modules/utility/init.zsh @@ -145,7 +145,11 @@ fi # Miscellaneous # Serves a directory via HTTP. -alias http-serve='python -m SimpleHTTPServer' +if (($+commands[python3]); then + alias http-serve='python -m http.server' +elif (($+commands[python2]); then + alias http-serve='python -m SimpleHTTPServer' +fi # # Functions