操作步骤
(1)安装依赖包argcomplete
sudo pip install 'argcomplete>=0.5.7'
(2)全局激活,对所有的pyhton包生效
sudo activate-global-python-argcomplete
(3)仅对pytest永久生效
register-python-argcomplete pytest >> ~/.bashrc
(4)仅对pytest当前登录窗口生效一次
eval "$(register-python-argcomplete pytest)"