gpt4 book ai didi

python - pipenv 和 bash 别名

转载 作者:太空狗 更新时间:2023-10-29 18:00:42 25 4
gpt4 key购买 nike

我在我的 .bash_profile (Mac) 中定义了一组核心的 bash 别名。但是,当我使用 pipenv shell 激活 pipenv 时,我的别名不起作用并且 bash alias 命令不返回任何内容。

生成从父 shell 继承 bash 别名的 pipenv shell 是否需要配置步骤?

最佳答案

别名永远不会被继承。 .bash_profile 仅用于登录 shell,而 pipenv 显然创建了一个非登录交互式 shell。别名应该在 .bashrc 中定义,在 Mac 上(终端仿真器默认启动登录 shell),添加 [[ -f ~/.bashrc ]] && source ~/.bashrc 到你的 .bash_profile 的末尾。

关于python - pipenv 和 bash 别名,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/46416052/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com