有沒有辦法將我最後一條ipython命令發送給腳本?ipython函數將最後一條命令發送給腳本
所需的使用會是這樣的:
$ tail script.py
...
[1] my_command = 0
[2] %saveLastCmd script.py # equivalent to $ echo <command> >> script.py
$ tail script.py
....
my_command = 0
[1] my_command = 1
[2] %saveLastCmd script.py # equivalent to $ echo <command> >> script.py
$ tail script.py
....
my_command = 0
my_command = 1
通過IPython的神奇功能,閱讀和打字我的問題到谷歌 – kilojoules