Skip to content

Instantly share code, notes, and snippets.

@abidibo
Last active October 20, 2017 10:47
Show Gist options
  • Save abidibo/5f39dc35650652a36967e2374e2d3180 to your computer and use it in GitHub Desktop.
Save abidibo/5f39dc35650652a36967e2374e2d3180 to your computer and use it in GitHub Desktop.
ROpe stuff for vim

Rope stuff

By default you can use <Ctrl-Space> for autocompletion

Autocompletion is also called by typing a period in |Insert| mode by default.

By default when you press <C-C>g on any object in your code you will be moved to definition.

Pymode can rename everything: classes, functions, modules, packages, methods, variables and keyword arguments.

Keymap for rename method/function/class/variables under cursor let g:pymode_rope_rename_bind = <C-c>rr

Organize imports sorts imports, too. It does that according to PEP8. Unused imports will be dropped. let g:pymode_rope_organize_imports_bind = <C-c>ro

Insert import for current word under cursor let g:pymode_rope_autoimport_bind = <C-c>ra

It happens when you perform move refactoring on a method of a class. In this refactoring, a method of a class is moved to the class of one of its attributes. The old method will call the new method. If you want to change all of the occurrences of the old method to use the new method you can inline it afterwards. let g:pymode_rope_move_bind = <C-c>rv

Change function signature let g:pymode_rope_change_signature_bind = <C-c>rs

:map rrag :call RopeGenerateAutoimportCache()

:map ra :call RopeAutoImport()

:map rrca :call RopeCodeAssist()

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment