Use python3 for http-serve alias if available (#1193)
This commit is contained in:
parent
2ba060a426
commit
8913bcccd2
1 changed files with 5 additions and 1 deletions
|
@ -158,7 +158,11 @@ fi
|
||||||
# Miscellaneous
|
# Miscellaneous
|
||||||
|
|
||||||
# Serves a directory via HTTP.
|
# Serves a directory via HTTP.
|
||||||
alias http-serve='python -m SimpleHTTPServer'
|
if (( $+commands[python3] )); then
|
||||||
|
alias http-serve='python3 -m http.server'
|
||||||
|
else
|
||||||
|
alias http-serve='python -m SimpleHTTPServer'
|
||||||
|
fi
|
||||||
|
|
||||||
#
|
#
|
||||||
# Functions
|
# Functions
|
||||||
|
|
Loading…
Add table
Reference in a new issue