Python 3 alias All In One
Python 3 alias All In One
python3 / py3 / python
# $ vim .zshrc
$ code .zshrc
$ source ~/.zshrc
$ py3 --version
Python 3.9.6
$ python --version
Python 3.9.6
$ python3 --version
Python 3.9.6
$ which py3
py3: aliased to python3
$ which python
python: aliased to /usr/bin/python3
$ which python3
/usr/bin/python3
demos
.zshrc
# ...
# Python 3 ✅
alias python=/usr/bin/python3
# Python3
alias py3='python3'
# export PATH="/usr/bin/python3:$PATH"
# export PATH="/usr/bin/:$PATH"
# $ cd /usr/bin/ && ls | grep "python" ✅
# $ cd /usr/bin/ && ls -al | grep "python" ✅
# .bash_profile
source ~/.bash_profile
# end zsh
# source ~/.zshrc
(🐞 反爬虫测试!打击盗版⚠️)如果你看到这个信息, 说明这是一篇剽窃的文章,请访问 https://www.cnblogs.com/xgqfrms/ 查看原创文章!
docs
Python
3.11.3
文档
https://docs.python.org/zh-cn/3/
https://www.runoob.com/python3/python3-tutorial.html
refs
©xgqfrms 2012-2021
www.cnblogs.com/xgqfrms 发布文章使用:只允许注册用户才可以访问!
原创文章,版权所有©️xgqfrms, 禁止转载 🈲️,侵权必究⚠️!
本文首发于博客园,作者:xgqfrms,原文链接:https://www.cnblogs.com/xgqfrms/p/17365954.html
未经授权禁止转载,违者必究!