[[email protected] ~]# cat 1.txt
1ms
2ms
3ms
4ms
5ms
[[email protected] ~]# cat 1.txt | awk ‘{print $1"\047"}‘
1ms‘
2ms‘
3ms‘
4ms‘
5ms‘
[[email protected] ~]# cat 1.txt | awk ‘{print $1"\047"}‘ > 2.txt
[[email protected] ~]# cat 2.txt
1ms‘
2ms‘
3ms‘
4ms‘
5ms‘
linux操作系统-给文本添加 ' -单引号,一般转成CSV格式时使用
时间: 2024-10-13 16:16:53