如何在 SublimeText 中用引号将每一行括起来? [英] How to wrap each line in quotes in SublimeText?
本文介绍了如何在 SublimeText 中用引号将每一行括起来?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
输入:
boston beach summer figural yellow blue
boston floral flowers still still-life food pink figural
boston horse pink purple house flowers floral figural
预期输出:
"boston beach summer figural yellow blue"
"boston floral flowers still still-life food pink figural"
"boston horse pink purple house flowers floral figural"
实际输入文件有 600 多行,我正在寻找一种将每一行括在引号中的快速方法?该方法是否涉及使用多个游标?宏呢?
The actual input file has 600+ lines, and I'm looking at a quick way to wrap each line in quotes? Does the method involve using multiple cursors? How about macros?
推荐答案
我会像这样使用多游标方法:
I would use a multiple cursors approach like this:
Windows
- Ctrl + A(全选)
- Ctrl + Shift + L(分行)
- End(将光标放在行尾)
- "(在行尾添加引号)
- Home(转到行的第一个字符)
- Home(转到行首...就像有制表符或空格一样)
- "(在行首添加引号)
- Ctrl + A (Select everything)
- Ctrl + Shift + L (Split into lines)
- End (Put the cursor at the end of the line)
- " (Add the quote at the end of the line)
- Home (Go to the first character of the line)
- Home (Go to the beginning of the line... like if you have tabs or spaces)
- " (Add the quote at the beginning of the line)
Mac
- Cmd + A(全选)
- Cmd + Shift + L(分行)
- Cmd + →(将光标放在行尾)
- "(在行尾添加引号)
- Cmd + ←(转到该行的第一个字符)
- Cmd + ←(转到行首......就像你有制表符或空格一样)
- "(在行首添加引号)
- Cmd + A (Select everything)
- Cmd + Shift + L (Split into lines)
- Cmd + → (Put the cursor at the end of the line)
- " (Add the quote at the end of the line)
- Cmd + ← (Go to the first character of the line)
- Cmd + ← (Go to the beginning of the line... like if you have tabs or spaces)
- " (Add the quote at the beginning of the line)
这篇关于如何在 SublimeText 中用引号将每一行括起来?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文