Commit Graph

1955 Commits

Author SHA1 Message Date
micbou
0588c23c70 Update Travis configuration 2015-08-23 23:27:13 +02:00
micbou
c99aa85de2 Convert run_tests script to python
Translate the run_tests.sh script in python to make it platform independent.
2015-08-23 23:27:02 +02:00
micbou
7d87bc3f82 Update documentation 2015-08-23 20:12:24 +02:00
micbou
1b40d683be Convert the install script to python
Translate the install.sh script in python to make it platform independent.
Keep install.sh as a wrapper of install.py to not break scripts that
depend on it.
2015-08-23 20:12:16 +02:00
Homu
cc94a96c9d Auto merge of #1641 - RyuKojiro:bashless, r=Valloric
Removed the bash dependency that install.sh had

People like me use YCM on machines that don't have bash, and it's nice to not have to add it unnecessarily. This removes the bash dependency for installation.
2015-08-22 13:49:11 +09:00
Daniel Loffgren
dd143bcaaa install.sh now works without bash, and preserves the trap functionality via exits 2015-08-21 03:22:09 +09:00
Strahinja Val Markovic
689b4e15a5 Rewording the YCM readme intro section
It's time to break the semantic language support up into bullets.
2015-08-18 20:11:39 -07:00
Strahinja Val Markovic
5fb4146a49 Updating to latest ycmd 2015-08-18 20:07:46 -07:00
Homu
33621d409b Auto merge of #1632 - puremourning:general-completions-when-no-semantic, r=Valloric
If errors are returned in addition to completion suggestions, print them

Needed for https://github.com/Valloric/ycmd/pull/198

This maintains the previous client behaviour when the semantic completer throws an exception.
2015-08-19 11:30:30 +09:00
Ben Jackson
258951ece4 If errors are returned in addition to completion suggestions, print them 2015-08-17 01:13:20 +01:00
Homu
9430aee4b3 Auto merge of #1628 - puremourning:update-vim-doc, r=Valloric
Update vim help

Includes recent changes including FixIt and some other minor tweaks
2015-08-17 00:52:33 +09:00
Ben Jackson
c73b4aa529 Update vim help
Includes recent changes including FixIt and some other minor tweaks
2015-08-15 00:55:23 +01:00
Homu
b88739001c Auto merge of #1612 - icholy:master, r=Valloric
Note TypeScript support in README
2015-08-13 09:12:03 +09:00
Ilia Choly
b1ad8bba48 Note TypeScript support in README 2015-08-12 00:36:44 -04:00
Strahinja Val Markovic
c5a5145082 Updating to latest ycmd 2015-08-05 17:14:45 -07:00
Homu
c946aa5fd4 Auto merge of #1555 - puremourning:fixit, r=Valloric
[RFC] YCM Client support for FixIt commands

This change provides the client-side support in YouCompleteMe for vim providing a new :YcmFixIt command which applies changes to the vim buffer to implement trivial fixes to common coding errors where the completer provides instructions on how to fix a diagnostic. A note is added "(FixIt)" to the diagnostic text echo'd in vim when a FixIt is available.

While this may seem out of the scope of ycmd/YouCompleteMe (as a completion engine), I think it is a really useful feature, and provided straight out of libclang. so I'm sending this slightly incomplete PR (along with the associated ycmd change) to see what the appetite is within the user and maintainer community, and to get feedback on the approach.

I know that I need to write some tests, and perhaps tidy up some TODOs, but I would really appreciate any feedback on the approach. Also, I should confess that I haven't yet run the existing tests as I'm having trouble getting them to run on my mac. Hoping that travis will help me out :)

I know I also need to update the readme.

Testing has been performed manually by going through the list of .c, .cpp and .m files in clang's tests/FixIt folder and ensuring that by hitting :YcmFixIt (actually "@:" a lot!) on each diagnostic, the diagnostic went away (assuming a FixIt was available). I also mangled a number of the clang test such that the fix was spread across multiple lines, etc.

I also haven't tested this with completers other than clang completer (due to having trouble one with diagnostics getting them to work) , but of course I will prior to this being ready to merge.

I also understand that adding the vim modelines might be divisive, but the standard in this project doesn't match my usual setting :) Happy to remove them if people react angrily.

Once again thanks for the time and a great (and improving!) product.

I have signed the CLA

Demo:
![ycmfixit](https://cloud.githubusercontent.com/assets/10584846/8396802/8fce516c-1dad-11e5-91e7-a26253e489fd.gif)
2015-08-06 06:31:08 +09:00
Ben Jackson
98c4d712b4 YouCompleteMe client support for FixIt subcommands 2015-08-05 22:09:07 +01:00
Homu
baaa8be65c Auto merge of #1619 - micbou:trigger-issues, r=Valloric
Fix trigger issues

Fix issues #1597 and #1598. These issues should contain enough information to understand the changes.

Thanks to @wladston.
2015-08-05 03:32:02 +09:00
Strahinja Val Markovic
337d1c1fb9 Doc update: no need to sign the Google CLA anymore 2015-08-03 16:35:30 -07:00
micbou
037bd0f6f1 Fix trigger issues
Fix the following cases where the completion is not triggered for
the next typed character:
 - moving vertically in insert mode,
 - removing a character and entering insert mode.
2015-08-03 22:32:57 +02:00
Homu
ef6892210a Auto merge of #1594 - wladston:master, r=Valloric
Updating default semantic hooks.

The documentation was updated to be in sync with ycmd @bfcfa21,
regarding default semantic hooks defined in ycmd's completer_utils.py.
2015-08-04 01:48:52 +09:00
Wladston Viana Ferreira Filho
0812cd815d Updating default semantic hooks.
The documentation was updated to be in sync with ycmd @bfcfa21,
regarding default semantic hooks defined in ycmd's completer_utils.py.
2015-07-22 23:21:36 -03:00
Val Markovic
b9dd9096a3 Merge pull request #1575 from douglasdrumond/patch-1
Update MacVim location
2015-07-08 15:59:37 -07:00
Douglas Drumond
2aa0dd86ec Update MacVim location
New MacVim site is located at GitHub. The repository is at
https://github.com/macvim-dev/macvim and releases page
at https://github.com/macvim-dev/macvim/releases
2015-07-07 06:04:03 -03:00
Strahinja Val Markovic
5796f52797 Whitespace fixes 2015-07-02 14:32:27 -07:00
Strahinja Val Markovic
53c44c6d44 Updating to latest ycmd 2015-07-02 14:25:46 -07:00
Val Markovic
d4b94ca7dc Merge pull request #1563 from micbou/windows-popen
Set stdin to PIPE on Windows only when necessary
2015-07-02 14:21:56 -07:00
micbou
0fd842a29e Set stdin to PIPE on Windows only when necessary
Executing the check_core_version.py script with SafePopen and stdin to
PIPE raises an error in Vim on Windows. Since the stdin option is only
useful when starting the ycmd server, it is only set in this case.
2015-07-02 20:47:13 +02:00
Strahinja Val Markovic
8505544d23 Deleting obsolete code 2015-07-02 08:38:27 -07:00
Strahinja Val Markovic
98d687a5e0 Updating to latest ycmd
Related to Valloric/ycmd#171
2015-07-01 17:52:51 -07:00
Strahinja Val Markovic
9de61988ac Fix bad formatting for YcmCompleter message
Fixes #1522
2015-06-30 14:24:05 -07:00
Strahinja Val Markovic
d1ce4dc4d0 Updating to latest ycmd 2015-06-30 13:53:00 -07:00
Strahinja Val Markovic
ecb4252322 Minor formatting fixes 2015-06-30 13:52:47 -07:00
Strahinja Val Markovic
2a443cd300 Updating to latest ycmd 2015-06-29 16:15:01 -07:00
Homu
66dcc9581c Auto merge of #1545 - micbou:echom-redraw, r=Valloric
Redraw the screen before displaying a message

There has been several complaints about the message "ValueError: File is less than 5 lines long; not compiling". See issues #814, #1364, #1544. In fact, I believe the issue is not the message itself but the infamous "Press ENTER or type command to continue" prompt when editing a new C-family file.

For example, if I create the file `foo.c`, Vim will display the line `"foo.c" [New file]` and then YouCompleteMe will display `ValueError: File is less than 5 lines long; not compiling`. Since there are now two lines, the hit-enter message is prompted. By redrawing the screen just before displaying the message from YouCompleteMe, only one line appears and we avoid this behavior.

Tested on Linux and Windows.

CLA signed.
2015-06-23 06:08:37 +09:00
micbou
69eee2097f Redraw the screen before displaying a message
This avoids the infamous "Press ENTER or type command to continue"
prompt when editing a new C-family file.
2015-06-20 05:57:01 +02:00
Homu
a24cc3c662 Auto merge of #1542 - vheon:fix-completer-available, r=Valloric
Fix check condition for setting omnifunction

I had the check for the omnifunc set backwards. I will start to see if we can start testing the vimscript layer as well. I have signed the CLA.
2015-06-19 05:30:28 +09:00
Andrea Cedraro
7bc05a37b5 Fix check condition for setting omnifunction 2015-06-18 14:08:06 +02:00
Homu
bc5f581b2d Auto merge of #1538 - vheon:fix-completer-available, r=Valloric
Fix completer available

Sorry, I deleted the branch on github by mistake. Here is the same changes from #1530 plus a buffer local variable, so we don't try to set the `omnifunc` everytime we enter insert mode. I signed the CLA.
2015-06-16 07:21:21 +09:00
Andrea Cedraro
fbdf7cc85e Reverse if logic in UpdateDiagnosticInterface 2015-06-15 16:08:56 +02:00
Andrea Cedraro
3dd24201f3 Revert "Revert "Check the server end point for available completer""
This reverts commit f5e2fc6958.
2015-06-15 16:08:56 +02:00
Andrea Cedraro
4104f7be82 Push check for NativeFiletypeCompletionUsable down
Another way in which the commit d768447 forced the client to wait for
the server to start was the UpdateDiagnosticNotifications call from the
FileReadyToParse which is called right after a buffer is loaded. In any
way if we don't have any previous FileReadyToParse request done for the
current file we bail out, so we we can wait for a FileReadyToParse
response to be available before asking if a completer is usable for the
current filetype.

ref: #1529
2015-06-15 16:08:56 +02:00
Andrea Cedraro
30036ca8e2 Defer setting the omnifunc.
When we enter a new buffer we need to know if the ycmd server has a
native completer for the current filetype, this means that when we start
vim we need to know if the server has a completer available for the
buffer which means that we have to wait for the server to be up and
running. To mitigate this defer the setting of the omnifunction closer
to its need which is when we enter insert mode; this should give room
for the ycmd server to start before we ask for anything or at least
should reduce the time waiting.

ref: #1529
2015-06-15 16:08:50 +02:00
Val Markovic
d77ef96ebc Merge pull request #1532 from vheon/fix-disable-filetype
Disable completion if any of current filetypes is disable
2015-06-12 10:02:18 -07:00
Andrea Cedraro
77947accf3 Disable completion if any of current filetypes is disable
Fixes #1531
2015-06-12 13:04:03 +02:00
Strahinja Val Markovic
f5e2fc6958 Revert "Check the server end point for available completer"
This reverts commit d7684470a2.

Fixes #1529
2015-06-11 12:37:40 -07:00
Val Markovic
1f073b122f Merge pull request #1524 from vheon/fix-completer-available
Check the server end point for available completer
2015-06-10 10:36:47 -07:00
Andrea Cedraro
d7684470a2 Check the server end point for available completer
Previously we were checking if the `hook.py` file existed for the given
filetype. ycmd has an endpoint for checking if given a filetype a
semantic completer is available. To avoid redundant requests we cache
those requests for every filetype. A semantic engine cannot be added
*after* the ycmd server is started so to avoid redundant requests we
cache those requests for every filetype and we clear the cache at server
setup, in this way if we issue a `YcmRestartServer` command the server
will be setup again and if a semantic completer is available we can use
it. Should fix #1284.
2015-06-09 13:09:25 +02:00
Val Markovic
9d63dc2bb6 Merge pull request #1517 from frankier/nul-c-space-neovim
Remap <Nul> to <C-Space> regardless of gui_running since it is an unreliable way of detecting terminals in neovim
2015-06-08 15:32:59 -07:00
Val Markovic
ed7f778a39 Merge pull request #1521 from The-Compiler/patch-1
Don't link to specific clang version
2015-06-08 15:27:13 -07:00