aboutsummaryrefslogtreecommitdiffstats
AgeCommit message (Collapse)Author
2017-12-20Increase version v0.0.4 -> v0.0.5v0.0.5Teddy Wing
2017-12-20Merge branch 'don,t-try-to-recall-if-there-hasn,t-been-a-G-movement-yet'Teddy Wing
2017-12-20autoload/grappele.vim: Only try to recall if a location was savedTeddy Wing
Previously, if `gG` (the recall mapping) was pressed before previously having pressed a `G` command, the following error would appear: Error detected while processing function grappele#Recall: line 1: E121: Undefined variable: s:line E116: Invalid arguments for function grappele#Grappele This happened because no previous `G` location had been saved. Displaying an error here makes for a bad user experience. Instead if this happens, we should just do nothing. To prevent the error, check for the existence of the `s:line` variable before trying to use it.
2017-07-09Increase version v0.0.3 -> v0.0.4v0.0.4Teddy Wing
2017-07-09autoload/grappele.vim: Don't save location when using `G` directlyTeddy Wing
Previously, we would save the location of the `G` command regardless of whether it was used with a count or not. Thus, `34G` and `G` would both save locations. Saving the location of `G` isn't really useful, but it's easily accessed. Instead, only save location when using a count with `G`. This allows the Grappele command to be useful even after having pressed `G`.
2016-06-17Increase version 0.0.2 -> 0.0.3v0.0.3Teddy Wing
* Update CHANGELOG * Increment version number in help file
2016-06-17autoload/grappele.vim: Push to jumplistTeddy Wing
Turns out that invoking `G` wouldn't push your movement to the jumplist (unlike Vim's real `G`). This was not only confusing, it was also wrong. Just an oversight on my part that I didn't notice until now.
2015-09-16Increase version v0.0.1 -> v0.0.2v0.0.2Teddy Wing
* Update version number in help file * Update CHANGELOG
2015-09-16plugin/grappele.vim: Silence `G` mappingTeddy Wing
Don't output the mapping result in the command line when using the `G` command. Was handling this prevously with the `<Plug>Grappele` mapping but not with the new one that I added in 07a75d523eadaf1027aa8bf287256602ad05f97f.
2015-09-14Add CHANGELOGv0.0.1Teddy Wing
Include information about the initial v0.0.1 release.
2015-09-14Add READMETeddy Wing
Include a description of the plugin, installation instructions (copied from one of my other plugins), and license information.
2015-09-14Add documentationTeddy Wing
Create a help file with information about the plugin, its primary use case, and information about its mappings (although one of them isn't really noticeable as a customised mapping). Also generate helptags.
2015-09-14Add LICENSETeddy Wing
MIT license
2015-09-14plugin/grappele.vim: Fix performance issue with `G`Teddy Wing
Looked into the performance issues I was having with the `G` command. After a little profiling and then messing around with let start = reltime() | <do stuff> | echom reltimestr(reltime(start)) Using the `reltime` method I discovered that `grappele#Grappele()` was running pretty quick (~60 time units). I then ran it around the :<c-u>call grappele#Grappele(v:count)<cr> part of the mapping and found that it took about 130 time units. Then doing nnoremap G :let start = reltime() \| execute 'normal! G' | echom reltimestr(reltime(start)) was pretty quick. With that information, I decided to try a direct mapping bypassing the `<Plug>` mapping just to see what that would do. Turns out the custom `G` command works much faster with this method for some reason. In terms of feel it's as fast as the normal `G` command. Replacing the `<Plug>` mapping with the direct one for speed. Not really sure what the reason for this is but I'm glad the performance is up to snuff and actually usable now. I'm testing this on OS X 10.8.5 with the stock Vim (7.3 (2010 Aug 15, compiled Jun 20 2012 13:16:02)). Also noticed this issue on my Debian server which I just found out uses the same version of Vim (7.3 (2010 Aug 15, compiled May 4 2012 04:25:35)).
2015-09-13Create G recall commandTeddy Wing
* Add mapping for the recall command. Using `gG` because it's quick, easy to remember, and doesn't appear to be used for anything. * Create `grappele#Recall()` function that goes to the last `G` count * Store the most recent count passed into `G` Using the recall command, you can `G` to the same count that you previously used no matter what buffer you're now in. TODO: The `G` command appears to be running slowly now for whatever reason. Investigate what's going on.
2015-09-13plugin/grappele.vim: Silence mappingTeddy Wing
Otherwise the mapped command is printed on the command line which isn't necessary and adds visual noise and distraction.
2015-09-13Replicate n_G functionalityTeddy Wing
Go to the end of the buffer when typed with no count, otherwise go to the line specified by `v:count`.
2015-09-13plugin/grappele.vim: Fix mapping (add missing <cr>)Teddy Wing
2015-09-13plugin/grappele.vim: Fix <Plug> mapping definitionTeddy Wing
Should be mapping `<Plug>Grappele` to the function call. `G` doesn't belong in this map call. That's what the one at the end is for.
2015-09-13Initial commit. Project setup.Teddy Wing
* Basic setup for the plugin: * `loaded` global * Create mapping definition based on style from tpope and System Copy * Create dummy function in autoload