Fix and improve Vim.Buffer.read_content/edit_content #466

Merged
merged 2 commits into from Jan 14, 2017

Projects

None yet

3 participants

@lambdalisue
Member
  1. Fix 'no such buffer' exception during 'read_content' (ref: lambdalisue/vim-gista#81 (comment))
  2. Add 'lockmarks' option to lock marks on the buffer
@lambdalisue lambdalisue added Review me and removed Review me labels Jan 12, 2017
@lambdalisue lambdalisue changed the title from Fix and improve Vim.Buffer.read_content/edit_content to RFC:Fix and improve Vim.Buffer.read_content/edit_content Jan 12, 2017
@lambdalisue
Member
lambdalisue commented Jan 12, 2017 edited

もしかして: execute 'bwipeout!' shellescape(tempfile) ってする必要が Windows の場合はあって、そのせいでエラーが出てた?(もしくは fnameescape)

もしもそうなら silent を愚直に足すべきではないので Windows の人試して頂けると助かります

@mattn
Member
mattn commented Jan 12, 2017

vim のコマンドの時は fnameescape、外部コマンドに渡す場合は shellescape と覚えまましょう。今回の場合は fnameescape す。

@mattn
Member
mattn commented Jan 12, 2017

ちなみに execute はエスケープ不要です。

@lambdalisue
Member

なるほどやはり。ありがとうございます!修正して--forceします

@lambdalisue lambdalisue changed the title from RFC:Fix and improve Vim.Buffer.read_content/edit_content to Fix and improve Vim.Buffer.read_content/edit_content Jan 13, 2017
lambdalisue added some commits Jan 12, 2017
@lambdalisue lambdalisue Vim.Buffer: Add 'lockmarks' option to lock marks 46ba78d
@lambdalisue lambdalisue Vim.Buffer: Use 'silent' and 'fnameescape'
fnameescape() is required while tempfile might contains
backslash in Windows.

silent is added while the line is for removing 'tempfile'
from unlisted-buffer which is not a core part of the
function (#439)

Fix lambdalisue/vim-gista#81
854ce5a
@thinca
thinca approved these changes Jan 14, 2017 View changes
@thinca thinca merged commit a3b3044 into master Jan 14, 2017

5 checks passed

continuous-integration/appveyor/branch AppVeyor build succeeded
Details
continuous-integration/appveyor/pr AppVeyor build succeeded
Details
continuous-integration/drone the build was successful
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
continuous-integration/travis-ci/push The Travis CI build passed
Details
@thinca thinca deleted the Vim-Buffer branch Jan 14, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment