IPython: redirecting output of a Python script to a file (like bash >)

后端 未结 7 2101
慢半拍i
慢半拍i 2020-12-01 03:50

I have a Python script that I want to run in IPython. I want to redirect (write) the output to a file, similar to:

python my_script.py > my_output.txt
         


        
7条回答
  •  醉话见心
    2020-12-01 04:01

    It seems a lot of code.... My solution. redirect output of ipython script into a csv or text file like sqlplus spool wonder there is an easy way like oracle sqlplus spool command..?

提交回复
热议问题