聚合国内IT技术精华文章,分享IT技术精华,帮助IT从业人士成长

How to paste in Vim

2021-07-16 13:20 浏览: 1917658 次 我要评论(0 条) 字号:

After I have written the SQL on BigQuery’s UI:

SELECT
  first_column
FROM
  `project.dataset.table`
ORDER BY
  `first_column` ASC
LIMIT
  1000

I tried to copy it to my Vim editor through “Ctrl + c” and “Ctrl + v”. But the result in my Vim looks like irregular steps

SELECT
  *
  FROM
    `project.dataset.table`
    ORDER BY
      `first_column` ASC
      LIMIT
        1000

Even using “Shift + Option + Command + v” to paste code without format couldn’t solve this problem.

Actually, it’s not a problem about system pasting, but about Vim. The correct way is to set Vim to accept “paste” at first

:set paste

then we can get the pasting content correctly.



网友评论已有0条评论, 我也要评论

发表评论

*

* (保密)

Ctrl+Enter 快捷回复