![PYTHONPATH 添加到哪里?](https://linux22.com/image/1195398/PYTHONPATH%20%E6%B7%BB%E5%8A%A0%E5%88%B0%E5%93%AA%E9%87%8C%EF%BC%9F.png)
当我用以下方式检查 PYTHONPATH 时
echo $PYTHONPATH
结果太复杂了。我想删除一些行。但是它不在 bashrc、profile 或 environment 文件中。有什么方法可以解决这个问题吗?
结果是:
/home/../carla-ros-bridge/install/rqt_carla_control/lib/python3.8/site-packages:/home/../carla-ros-bridge/install/carla_waypoint_publisher/lib/python3.8/site-packages:/home/../carla-ros-bridge/install/carla_ackermann_control/lib/python3.8/site-packages:/home/../carla-ros-bridge/install/carla_ros_bridge/lib/python3.8/site-packages:/home/../carla-ros-bridge/install/carla_spawn_objects/lib/python3.8/site-packages:/home/../carla-ros-bridge/install/carla_manual_control/lib/python3.8/site-packages:/home/../carla-ros-bridge/install/carla_ad_agent/lib/python3.8/site-packages:
并且它对此进行了更多介绍。一些线路重复并且路径错误。
编辑:我export PYTHONPATH=
直接从终端使用,没有将它们写入文件中。但是,我的问题是,即使我没有将其保存到任何文件中,系统是否会将其写入文件中?因为我想删除所有这些复杂的 PYTHONPATH。