我一直在使用sep来尝试这个,基本上我有一个文本文件,其中包含相同数量的相同行,例如
4444 username "some information" "someotherinformation" "even more information"
Run Code Online (Sandbox Code Playgroud)
我需要用下划线替换引号内的空格,所以它看起来像这样
4444 username "some_information" "someotherinformation" "even_more_information"
Run Code Online (Sandbox Code Playgroud)
目前我已经能够分离出引用的信息
sed 's/"\([^"]*\)"/_/g' myfile.txt
Run Code Online (Sandbox Code Playgroud)
关于如何进行的建议?