Commit Graph

7217 Commits

Author SHA1 Message Date
Shougo
b98da8de98 vim-patch:7.4.1910 (#5948)
Problem:    Tests using external command to delete directory.
Solution:   Use delete().

abc70bbf36
2017-01-15 00:44:16 +01:00
Shougo
1474304224 vim-patch:7.4.1851 (#5947)
Problem:    test_syn_attr failes when using the GUI. (Dominique Pelle)
Solution:   Escape the font name properly.

180fc2d418
2017-01-15 00:41:43 +01:00
James McCoy
a265ff448e Merge pull request #5940 from jamessan/master
job: Consume content from rbuffer before invoking the callback again
2017-01-14 07:49:51 -05:00
James McCoy
bde9bedb0b
job: Consume content from rbuffer before invoking the callback again
While a job callback is active, it may be invoked again.  Since the
data handled by the first invocation of the callback hasn't been marked
as consumed, the subsequent invocation will see the same data.

Reported-by: Daniel Hahler
Patch-by: oni-link
Closes #5889
2017-01-14 07:49:07 -05:00
Justin M. Keyes
58ba3bcbef Merge #5936 from blueyed/vim-8.0.0121
vim-patch:8.0.0121
2017-01-14 12:29:46 +01:00
James McCoy
947f1ebcb9 Merge pull request #5941 from blueyed/better-clint-note
src/clint.py: improve "Ignoring" message
2017-01-13 20:47:41 -05:00
Daniel Hahler
980bf1e548 Linting 2017-01-13 23:41:00 +01:00
Daniel Hahler
a0b33b333e vim-patch:8.0.0121
Problem:    Setting 'cursorline' changes the curswant column. (Daniel Hahler)
Solution:   Add the P_RWINONLY flag. (closes vim/vim#1297)

a2477fd349
2017-01-13 23:40:59 +01:00
Daniel Hahler
0aa1cff604 src/clint.py: improve "Ignoring" message
It was a bit confusing for me when seeing it myself the first time.

[ci skip]
2017-01-13 22:19:47 +01:00
Justin M. Keyes
f686635420 Merge #5933 from justinmk/dir-bufenter
open_buffer(): Raise `BufEnter` for directories.
2017-01-13 04:09:37 +01:00
Justin M. Keyes
82edcb593b Windows: enable more tests 2017-01-13 01:17:12 +01:00
Justin M. Keyes
cc7f1aba46 test: BufEnter 2017-01-13 01:17:11 +01:00
Justin M. Keyes
b5e8e2f20d lint 2017-01-13 01:17:11 +01:00
James McCoy
802b49ee80 Merge pull request #5935 from jamessan/dictwatcher-crash
eval: Remove dictwatcher from watchers queue before freeing it
2017-01-12 18:24:19 -05:00
Justin M. Keyes
42c922b32c open_buffer(): Do BufEnter for directories.
Abuse NOTDONE to give some nuance to the return value of readfile(), so
that open_buffer() can distinguish between "failed, lol" and "failed
because the path is a directory".

Before this change, Vim *already* creates a new buffer when a directory
is edited. So there is no reason it should not raise BufEnter, that was
an implementation detail of ye olde readfile().

Most of the changes in this commit merely preserve the old semantics.
The "implicit" change that we actually are interested in, is this line
in `open_buffer()`, where `retval` being non-FAIL allows EVENT_BUFENTER
to be applied:

    apply_autocmds_retval(EVENT_BUFENTER, NULL, NULL, FALSE, curbuf, &retval);

References https://github.com/vim/vim/issues/1353
2017-01-12 23:10:38 +01:00
James McCoy
674db4b01f eval: Remove dictwatcher from watchers queue before freeing it
This fixes a use-after-free noticed by ASAN which would occur when a
dictwatcher was still active on a dictionary when the dictionary was
freed.

    fun! MakeWatch()
      let d = {'foo': 'bar'}
      call dictwatcheradd(d, 'foo', function('...'))
    endfun

Patch-by: oni-link
Closes #5930
2017-01-12 14:47:43 -05:00
James McCoy
50d0d89129 Merge pull request #5932 from jamessan/icm-fixes
inccommand: Ignore errors during preview and make cmd_can_preview stricter
2017-01-12 06:45:03 -05:00
James McCoy
f2dff86493
inccommand: Preview :sub commands only after the delimiter is present
Closes #5888
2017-01-11 21:05:02 -05:00
James McCoy
dcd77c64ef
inccommand: Suppress error reporting when previewing commands
Closes #5912
2017-01-11 21:05:02 -05:00
Justin M. Keyes
207ba359b0 Windows: vim_getenv(): Find runtime relative to nvim. #3303 (#5929)
In Windows we cannot rely on absolute install paths to point to the
location of the runtime. Vim uses the path of the current binary as
a possible location for the runtime folder. In Neovim the install
location places the runtime folder in ../share/nvim/runtime.

In Vim this logic is guarded by USE_EXE_NAME, which is defined for win32
and macOS.

TODO: We may need to incorporate similar logic for macOS:
0cdb72aa38/src/misc1.c (L4287-L4308)
2017-01-11 06:00:55 +01:00
Justin M. Keyes
a08d2f54a0 Merge #5910 from justinmk/win32-jobstart
Windows: fix jobstart()
2017-01-11 02:19:11 +01:00
Justin M. Keyes
9ecdce1d53 test: system([...]): v:shell_error 2017-01-11 01:05:56 +01:00
Rui Abreu Ferreira
1e079fa987 system([...]): Set v:shell_error=-1 if not executable.
Do _not_ set v:shell_error on parameter validation error.

system([...]) does not invoke a shell, so this change is somewhat
questionable. But `:help v:shell_error` is sufficiently vague to allow
-1 in this case.
2017-01-11 01:05:55 +01:00
Rui Abreu Ferreira
4178e865d5 Windows: ci/AppVeyor: Enable Python provider tests
Setup python2/3 and install the Neovim client in Appveyor to
enable the python tests.

- Use the Python installation provided by Appveyor, because dependencies
  pyuv, greenlet have issues compiling with MinGW-w64. And this way we
  avoid building those too.
- Copy python.exe => python3.exe so that the python provider can find
  python3.
2017-01-11 01:05:55 +01:00
Rui Abreu Ferreira
ac44d0ed54 test: system([...]) 2017-01-11 01:05:55 +01:00
Marco Hinz
15c85d8462 clipboard: only check for pbcopy on macOS (#5927)
Fixes #5926.
2017-01-11 00:50:07 +01:00
Rui Abreu Ferreira
a05ebf4a2d Windows: libuv_process_spawn(): Allow libuv argument quoting/escaping.
Closes #5360
References #3305
Reverts commit dc9652e68d.

Disabling the quoting was does not solve the problem in general, and
we would end up having to handle the quoting ourselves.

See: https://github.com/JuliaLang/julia/issues/13776
2017-01-10 23:34:04 +01:00
James McCoy
8a5962023f Merge pull request #5924 from jamessan/vim-7.4.2100
vim-patch:7.4.2100
2017-01-10 15:32:29 -05:00
James McCoy
fc47bd92df lint 2017-01-10 13:05:41 -05:00
James McCoy
4c3204097c vim-patch:7.4.2100
Problem:    "cgn" and "dgn" do not work correctly with a single character
            match and the replacement includes the searched pattern. (John
            Beckett)
Solution:   If the match is found in the wrong column try in the next column.
            Turn the test into new style. (Christian Brabandt)

6835dc61ae

Closes #5796
2017-01-10 13:05:41 -05:00
James McCoy
6095c5df45 Merge pull request #5863 from ZyX-I/more-clint-checks
More clint brace checks
2017-01-10 11:43:14 -05:00
James McCoy
77de73c7c8 Merge pull request #5919 from jamessan/vim-7.4.2008
vim-patch:7.4.2008,7.4.2009
2017-01-10 09:56:53 -05:00
James McCoy
f3c93fbefe
lint 2017-01-10 07:14:24 -05:00
James McCoy
9b47115d53
vim-patch:7.4.2009
Problem:    Messages test fails.
Solution:   Don't set redir_execute before returning.

ed59aa60d3
2017-01-10 07:14:24 -05:00
James McCoy
6520517e22
vim-patch:7.4.2008
Problem:    evalcmd() has a confusing name.
Solution:   Rename to execute().  Make silent optional.  Support a list of
            commands.

79815f1ec7
2017-01-10 07:14:12 -05:00
James McCoy
9fcf6d577f Merge pull request #5862 from jamessan/vim-aa3b15d
vim-patch:aa3b15d,82af871,7.4.1925,c95a302
2017-01-09 22:31:45 -05:00
James McCoy
8f32c04df4
vim-patch:c95a302
Updated runtime files.

c95a302a4c
2017-01-09 20:24:08 -05:00
James McCoy
492f2cfeff
vim-patch:7.4.1925
Problem:    Viminfo does not merge file marks properly.
Solution:   Use a timestamp.  Add the :clearjumps command.

2d35899721
2017-01-09 20:23:41 -05:00
James McCoy
282109c51b
vim-patch:82af871
Updated runtime files.

82af8710bf
2017-01-09 20:23:41 -05:00
James McCoy
60e306368d
vim-patch:aa3b15d
Updated runtime files.

aa3b15dbeb
2017-01-09 20:23:41 -05:00
James McCoy
b260004d65 Merge pull request #5860 from jamessan/vim-7.4.1889
vim-patch:7.4.1889
2017-01-09 20:20:03 -05:00
Justin M. Keyes
94101987a5 process_wait(): Avoid dereference after LOOP_PROCESS_EVENTS. (#5917) 2017-01-09 01:42:58 +01:00
Justin M. Keyes
1420e10474 Merge #5519 from blueyed/improve-python-health-check
Improve Python health check
2017-01-09 00:07:13 +01:00
Marco Hinz
370379a486 health: completion for :CheckHealth 2017-01-08 23:49:11 +01:00
Daniel Hahler
35988b93e1 healthcheck: s:download: do not report curl errors (twice)
Since `curl -s` is used, the actual error (e.g. "curl: (6) Could not
resolve host: pypi.python.org") gets not reported anyway, and s:download
returns an error message with `s:shell_error` already.
This changes `s:download` to also include `a:url` in the error message
now.

It removes

> ERROR: Command error (7) curl -sL https://pypi.python.org/pypi/neovim/json:

And changes

> ERROR: HTTP request failed: error: curl error with https://pypi.python.org/pypi/neovim/json: 6
2017-01-08 23:26:47 +01:00
Daniel Hahler
7db0017f4e healthcheck: s:check_python: only report latest with good response 2017-01-08 23:26:47 +01:00
Daniel Hahler
adf32e1403 healthcheck: python: prefer neovim.VERSION 2017-01-08 23:26:46 +01:00
Daniel Hahler
5ce50504f9 healthcheck: python: include nvim path for unknown/outdated version
This helps to identify where the `neovim` module is coming from, e.g.

    - INFO: python3-neovim version: 0.1.10 (outdated; from ~/Vcs/neovim-python-client/neovim)
    - WARNING: Latest python3-neovim is NOT installed: 0.1.12
2017-01-08 23:26:46 +01:00
Daniel Hahler
0583ca63a5 Improve error reporting for Python health check
- s:version_info: return errors from the `import`
 - skip report_ok for latest version, in case the current version was
   not found.  status contains the error that has been reported in that
   case already.
2017-01-08 23:26:42 +01:00
Daniel Hahler
339dd4b1fb s:check_python: handle 'pip install --user -e' 2017-01-08 23:25:45 +01:00