在脚本仍在运行时,如何使用vim编辑Perl中的文本?(How can I use vim to edit text from Perl while the script is still running?)
我有一个输出文本的Perl脚本。 我想将这个文本导入到vim中,编辑它,保存并退出。 退出时,我想要原始的Perl脚本来处理编辑后的文件。
EG在添加新作业时crontab -e如何工作。
谢谢 :)
I have a Perl script that outputs text. I want to import this text into vim, edit it, save it and then exit. On exit, I want the original Perl script to process the edited file.
E.G. how crontab -e works when you add a new job.
Thanks :)
最满意答案
听起来像使用系统在文件名上运行vim很简单的情况。 这将等到vim完成,然后您可以继续阅读文件的新内容。
Sounds like a very plain case to use system to run vim on the filename. That will wait until vim is done, at which point you can go ahead and read the file's new contents.
更多推荐
发布评论