[ヒント]PychatはVirtualenvを自動的にアクティブ化(パラメータ自動仮想環境の実行)


# Environment

  • OS : windows 10
  • Terminal : Git Bash
  • PyCharm 2021.2 (Professional Edition)
  • いいえ、明らかにmacOS
    [File] -> [Settings] -> [Project: ] -> [Python Interpreter]Python Interpreterの仮想環境を設定します.
    Terminalを実行すると、仮想環境もアクティブになったようです.

    だめだよ...
    グーグルを通じて、スタックオーバーフローのお兄さんの助けを得ました.

  • Create .pycharmrc file

  • Write commands in .pycharmrc
  • source "$HOME/.bashrc"
    conda activate project---Codeforces.gg

  • [File] -> [Settings] -> [Tools] -> [Terminal]

  • Add --rcfile .pycharmrc parameters to Shell path

  • 結果...

    端末の実行時に仮想環境が自動的にアクティブ化されていることがわかります!

    # References

  • How do I activate a virtualenv inside PyCharm's terminal? - stackoverflow