From 1ac02b580d0f01112c2e0be758b417406b37840c Mon Sep 17 00:00:00 2001 From: excusemejoe Date: Fri, 20 Jan 2017 19:47:57 +0800 Subject: [PATCH 1/7] Update README.md 1. Correct the status of this project. (it's "released") 2. No need to show "completeness". --- README.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index da9c484..65dc175 100644 --- a/README.md +++ b/README.md @@ -62,17 +62,17 @@ Now vim-codequery works better than what you see by using Vim8's async feature. ## Schedule -> **This project is almost ready to be released.** +> **This project is released.** > > Main TODO: > * ~~Use Vim8's new features to enhance usability.~~ > * ~~Do lazy-loading.~~ -> * Enhance usability. -> * Test it. +> * ~~Enhance usability.~~ +> * ~~Test it.~~ +> * Add **explain** command in v1.0.0 > * Doc it. > -> Completeness: 94% -> Current Version: v0.9 +> Current Version: v0.9.1 > > Welcome to try it! 👌 From 020a8a83457b2a60c66ba4e9cd83897d509a120c Mon Sep 17 00:00:00 2001 From: excusemejoe Date: Sun, 2 Jul 2017 15:02:47 +0800 Subject: [PATCH 2/7] Update README.md Added installation guide for using Vim8's package system. --- README.md | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 65dc175..e40091a 100644 --- a/README.md +++ b/README.md @@ -114,7 +114,13 @@ Plug 'tpope/vim-dispatch' " if you don't have an :Ack (or :Ag) liked command Plug 'mileszs/ack.vim' ``` - +* In case you prefer to use Vim8's native package manager to manage plugins manually. Here comes an installation guide for that: + 1. Go to `~/.vim` + 2. Run `mkdir -p pack/vim-codequery/start/` and then go to `start` directory + 3. Run `git clone https://github.com/devjoe/vim-codequery` to get latest vim-codequery code + 4. It's done. 😎 Now `vim-codequery` will be loaded when your Vim starts. You can install [unite](https://github.com/Shougo/unite.vim) in the same way + 5. Learn more about Vim8's package system by typing `:help package | only` +  
## Usage From 745321f0ac613c493b9c4857cf6ba637da5d3567 Mon Sep 17 00:00:00 2001 From: excusemejoe Date: Mon, 1 Jan 2018 16:27:50 +0800 Subject: [PATCH 3/7] Update README.md Use github.io instead of dropbox to host static files --- README.md | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/README.md b/README.md index e40091a..517081f 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ ![](https://github.com/ruben2020/codequery/raw/master/doc/logotitle.png) - + > Choose what you want to know! 😼 ```vim @@ -46,11 +46,11 @@ This Vim plugin is built on top of the great tool [CodeQuery](https://github.com `Choose a query from menu ➙ Get results` -![](https://db.tt/rf6fO2eJ) +![](https://devjoe.github.io/public/cq_demo1.gif) `... ➙ Switch to different query ➙ Get results ... ➙ Filter them ➙ Get Results ➙ Undo ➙ Redo` -![](https://db.tt/KoZORec3) +![](https://devjoe.github.io/public/ca_demo2.gif) [more demo and screenshots](https://github.com/devjoe/vim-codequery/wiki/Screenshots-and-Demo) @@ -234,7 +234,7 @@ Currently, vim-codequery only provides [Unite](https://github.com/Shougo/unite.v " [F] means this action is for 'function variable only' " [C] is for 'class variable only' ``` - + * **Magic Unite menu** @@ -243,10 +243,10 @@ Currently, vim-codequery only provides [Unite](https://github.com/Shougo/unite.v " This menu changes dynamically: " 1. If the word under your cursor begins with a capital letter (possible be class): show [C] actions -" 2. vice versa (possible be function): show [F] actions +" 2. Vice versa (possible be function): show [F] actions " 3. Show reasonable actions within Quickfix ``` - +
@@ -365,8 +365,6 @@ let g:codequery_enable_not_so_magic_menu = 1 ## How to Contribute #### Use It -> And give me [feedback](https://goo.gl/forms/9r8sOS6xTCBjNQEW2) or [bug report](https://docs.google.com/spreadsheets/d/1eSweAzJKYdzeNdTUVfhujEAOy1RHq1_bEBSX8DQ6xvA/edit?usp=sharing). - #### Fork It > And give me PR. It would be better if you open an [issue](https://github.com/devjoe/vim-codequery/issues) and discuss with me before sending PR. From 0a07f54cad955f310680a5c3e7464838bcc2b112 Mon Sep 17 00:00:00 2001 From: syslot Date: Tue, 20 Mar 2018 14:36:29 +0800 Subject: [PATCH 4/7] modify neovim with sync method --- autoload/codequery.vim | 2 +- autoload/codequery/query.vim | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/autoload/codequery.vim b/autoload/codequery.vim index 973c6ff..bab9c2f 100644 --- a/autoload/codequery.vim +++ b/autoload/codequery.vim @@ -137,7 +137,7 @@ function! codequery#make_codequery_db(args) abort continue endif - if v:version >= 800 + if v:version >= 800 && !has('nvim') echom 'Making DB ...' let mydict = {'db_path': db_path, \'callback': function("codequery#db#make_db_callback")} diff --git a/autoload/codequery/query.vim b/autoload/codequery/query.vim index 7c8cf24..c144719 100644 --- a/autoload/codequery/query.vim +++ b/autoload/codequery/query.vim @@ -197,7 +197,7 @@ function! codequery#query#do_query(word) abort return endif - if v:version >= 800 + if v:version >= 800 && !has('nvim') echom 'Searching ... [' . a:word . ']' let job_dict = {'is_append': g:codequery_append_to_qf ? 1 : 0, From 6730879131d252d261e21510bd252fde8c9ea287 Mon Sep 17 00:00:00 2001 From: devjoe Date: Thu, 10 May 2018 00:58:39 +0800 Subject: [PATCH 5/7] apply johnzeng's patch according to https://github.com/devjoe/vim-codequery/issues/16 --- autoload/codequery.vim | 8 +++++++- autoload/codequery/db.vim | 5 +++++ 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/autoload/codequery.vim b/autoload/codequery.vim index bab9c2f..e267ec8 100644 --- a/autoload/codequery.vim +++ b/autoload/codequery.vim @@ -137,7 +137,13 @@ function! codequery#make_codequery_db(args) abort continue endif - if v:version >= 800 && !has('nvim') + if has('nvim') + echom 'Making DB ...' + let mydict = {'db_path': db_path, + \'callback': function("codequery#db#make_db_nvim_callback")} + let callbacks = {'on_exit': mydict.callback} + let s:build_job = jobstart(['/bin/sh', '-c', shell_cmd], callbacks) + elseif v:version >= 800 echom 'Making DB ...' let mydict = {'db_path': db_path, \'callback': function("codequery#db#make_db_callback")} diff --git a/autoload/codequery/db.vim b/autoload/codequery/db.vim index 3801e69..0534810 100644 --- a/autoload/codequery/db.vim +++ b/autoload/codequery/db.vim @@ -41,6 +41,11 @@ function! codequery#db#make_db_callback(job, status) dict endfunction +function! codequery#db#make_db_nvim_callback(job, data, status) dict + echom 'Done! Built codequery db!' +endfunction + + function! codequery#db#construct_python_db_build_cmd(db_path) abort let find_cmd = 'find . -iname "*.py" > python_cscope.files' let pycscope_cmd = 'pycscope -f "python_cscope.out" -i python_cscope.files' From 4ba24b83546c50a01e3c41ab7a9f12f967aee2d6 Mon Sep 17 00:00:00 2001 From: devjoe Date: Thu, 10 May 2018 01:07:09 +0800 Subject: [PATCH 6/7] update readme --- README.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 517081f..4e559af 100644 --- a/README.md +++ b/README.md @@ -25,7 +25,7 @@ This Vim plugin is built on top of the great tool [CodeQuery](https://github.com * Support asynchronous search (Vim version >= 8.0) 2. **Manage your database easily**. * Load, make and move your database file by custom Vim commands. - * Support asynchronous build (Vim version >= 8.0 or by `Dispatch` plugin) + * Support asynchronous build (Vim version >= 8.0 or NeoVim or by `Dispatch` plugin) * `Note: CodeQuery's SQLite database is built on top of ctags and cscope.` 3. **Know your code more instantly**. * (TBD) @@ -69,10 +69,12 @@ Now vim-codequery works better than what you see by using Vim8's async feature. > * ~~Do lazy-loading.~~ > * ~~Enhance usability.~~ > * ~~Test it.~~ +> * ~~Support NeoVim at a certain level.~~ > * Add **explain** command in v1.0.0 +> * Make UI be optional > * Doc it. > -> Current Version: v0.9.1 +> Current Version: v0.9.2 > > Welcome to try it! 👌 From 17ea93d6de13fff03abc58b3c7d53aeb85266f51 Mon Sep 17 00:00:00 2001 From: devjoe Date: Thu, 10 May 2018 01:24:53 +0800 Subject: [PATCH 7/7] add contributors to readme --- README.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/README.md b/README.md index 4e559af..a30a5a5 100644 --- a/README.md +++ b/README.md @@ -377,6 +377,13 @@ let g:codequery_enable_not_so_magic_menu = 1
+## Contributors +* [devjoe](https://github.com/devjoe) +* [johnzeng](https://github.com/johnzeng) +* [syslot](https://github.com/syslot) + +
+ ## Credits Thank all for working on these great projects!