ํ๊ฒฝ ๋ณ์๋ก IPython ํ๋กํ์ผ์ ์ค์ ํ๋ ๊ฒ์ด ์ข์ ๊ฒ์ ๋๋ค.
$ IPYTHON_PROFILE=testing ipython
Python 3.7.4 (default, Aug 13 2019, 20:35:49)
Type 'copyright', 'credits' or 'license' for more information
IPython 7.7.0 -- An enhanced Interactive Python. Type '?' for help.
IPython profile: testing
In [1]:
๋ด ํน์ ์ฌ์ฉ ์ฌ๋ก๋ conda {de,}activate.d/ ํํฌ๋ฅผ ์ฌ์ฉํ์ฌ ํ์ฑํ๋ conda ํ๊ฒฝ์ ๋ฐ๋ผ ํ๋กํ์ ๋ณ๊ฒฝํ๋ ๊ฒ์
๋๋ค. ํ์ฌ ์ฌ์ด ํดํน์ ipython
๋ฅผ ipython --profile={profile}
๋ก ๋ณ์นญํ ๋ค์ ๋นํ์ฑํ์์ ๋ณ์นญ์ ํด์ ํ๋ ๊ฒ์ด์ง๋ง ํ๊ฒฝ ๋ณ์๊ฐ ๋ ๊นจ๋ํ ๊ฒ์
๋๋ค.
$IPYTHONDIR ์ค์ ์ ์๋ํ์ต๋๊น?
https://ipython.readthedocs.io/en/stable/config/intro.html?highlight=ipythondir#envvar -IPYTHONDIR
$IPYTHONDIR์ ์ฌ์ฉํ๋ฉด $HOME/.ipython
(ํ๋กํ์ด ์๋ ์์น)๋ฅผ ์ ํํ ํ๋กํ์ด ์๋ ๋ค๋ฅธ ์์น๋ก ์ฌ์ ์ํ ์ ์์ต๋๋ค.
๊ฐ ํ๋กํ์ด ์์ฒด .ipython ๋๋ ํ ๋ฆฌ์ ์๋ ํดํน์ด ์์ ์ ์์ง๋ง ์ด๊ฒ์ ๋ณ์นญ ํธ๋ฆญ๋ณด๋ค ๋์ฉ๋๋ค.
:+1:
์ด ๊ธฐ๋ฅ์ด ์์ผ๋ฉด ์ข์ ๊ฒ ๊ฐ์ต๋๋ค. ๋ง์ ์์ฉ ํ๋ก๊ทธ๋จ์์ ํ์ค ์
ธ ๋์ IPython์ ์ฌ์ฉํ ์ ์์ง๋ง ํธ์ถํ ๋ ํ๋กํ์ ์ง์ ํ ์ ์์ต๋๋ค.
๊ฐ์ฅ ์ ์ฉํ ๋๊ธ
:+1:
์ด ๊ธฐ๋ฅ์ด ์์ผ๋ฉด ์ข์ ๊ฒ ๊ฐ์ต๋๋ค. ๋ง์ ์์ฉ ํ๋ก๊ทธ๋จ์์ ํ์ค ์ ธ ๋์ IPython์ ์ฌ์ฉํ ์ ์์ง๋ง ํธ์ถํ ๋ ํ๋กํ์ ์ง์ ํ ์ ์์ต๋๋ค.