Skip to content

Instantly share code, notes, and snippets.

diff -r 7af530381fec src/eval.c
--- a/src/eval.c Sun Aug 17 17:24:07 2014 +0200
+++ b/src/eval.c Tue Aug 19 03:23:32 2014 +0900
@@ -365,6 +365,7 @@
{VV_NAME("oldfiles", VAR_LIST), 0},
{VV_NAME("windowid", VAR_NUMBER), VV_RO},
{VV_NAME("progpath", VAR_STRING), VV_RO},
+ {VV_NAME("command", VAR_STRING), VV_RO},
};
diff -r 36bb83cc6202 src/edit.c
--- a/src/edit.c Sat Nov 15 08:13:55 2014 +0900
+++ b/src/edit.c Sat Nov 15 08:46:02 2014 +0900
@@ -2505,6 +2505,10 @@
return FAIL;
if (len < 0)
len = (int)STRLEN(str);
+ if (compl_first_match != NULL
+ && STRNCMP(compl_first_match->cp_str, str, len) == 0
+ && compl_first_match->cp_str[len] == NUL)
diff -r ab36689121ad src/edit.c
--- a/src/edit.c Wed Dec 17 21:00:49 2014 +0100
+++ b/src/edit.c Wed Jan 07 10:55:32 2015 +0900
@@ -34,8 +34,10 @@
#define CTRL_X_OMNI 13
#define CTRL_X_SPELL 14
#define CTRL_X_LOCAL_MSG 15 /* only used in "ctrl_x_msgs" */
+#define CTRL_X_EVAL 16 /* for builtin function complete() */
#define CTRL_X_MSG(i) ctrl_x_msgs[(i) & ~CTRL_X_WANT_IDENT]
let s:self_version = expand('<sfile>:t:r')
let s:self_file = expand('<sfile>')
" Note: The extra argument to globpath() was added in Patch 7.2.051.
let s:globpath_third_arg = v:version > 702 || v:version == 702 && has('patch51')
let s:loaded = {}
let s:cache_module_path = {}
let s:cache_sid = {}
@Shougo
Shougo / snake.py
Last active August 29, 2015 14:21 — forked from tarruda/snake.py
# Snake for Neovim! Adapted from https://gist.github.com/sanchitgangwar/2158084
# To install, create a ~/.vim/rplugin/python/snake.py file with this
# code, then run `nvim -c 'UpdateRemotePlugins' -c 'q'` from a shell.
#
# Make sure you have read the internal help explaining how to setup python
# host for external plugins(:help nvim-python)
#
# To start a new game, use the `:SnakeStart` command on an empty buffer(uses 80
# columns and 20 rows)
from threading import Thread, Lock
" ----------------------------------------------------------------------------
" vimawesome.com
" ----------------------------------------------------------------------------
function! VimAwesomeComplete() abort
let prefix = matchstr(strpart(getline('.'), 0, col('.') - 1), '[.a-zA-Z0-9_/-]*$')
echohl WarningMsg
echo 'Downloading plugin list from VimAwesome'
echohl None
ruby << EOF
require 'json'
let s:hosts = {}
let s:plugin_patterns = {
\ 'python': '*.py',
\ 'python3': '*.py',
\ }
let s:remote_plugins_manifest = fnamemodify($MYVIMRC, ':p:h')
\.'/.'.fnamemodify($MYVIMRC, ':t').'-rplugin~'
" Register a host by associating it with a factory(funcref)
diff -r ca3db36a6ed8 runtime/doc/autocmd.txt
--- a/runtime/doc/autocmd.txt Thu May 14 05:56:09 2015 +0200
+++ b/runtime/doc/autocmd.txt Fri May 29 12:31:07 2015 +0900
@@ -505,6 +505,8 @@
CompleteDone After Insert mode completion is done. Either
when something was completed or abandoning
completion. |ins-completion|
+ The |v:completed_item| variable contains the
+ completed item.
local helpers = require('test.functional.helpers')
local clear, feed, execute = helpers.clear, helpers.feed, helpers.execute
local eval, eq, neq = helpers.eval, helpers.eq, helpers.neq
local execute, source = helpers.execute, helpers.source
describe("completion", function()
before_each(function()
clear()
end)
@Shougo
Shougo / __init__.py
Last active August 29, 2015 14:22
deoplete.py
#=============================================================================
# FILE: __init__.py
# AUTHOR: Shougo Matsushita <Shougo.Matsu at gmail.com>
# License: MIT license {{{
# Permission is hereby granted, free of charge, to any person obtaining
# a copy of this software and associated documentation files (the
# "Software"), to deal in the Software without restriction, including
# without limitation the rights to use, copy, modify, merge, publish,
# distribute, sublicense, and/or sell copies of the Software, and to
# permit persons to whom the Software is furnished to do so, subject to