Fork of adoy/vim-php-refactoring-toolbox
.
Big thanks to Pierrick Charron (@adoy).
A set of mappings which help you to refactor code in consistent way across languages.
- PHP
- Shell
- Extract Method
- JavaScript
- Extract Method
- Extract Variable
- Inline Variable
- Rename Variable
- TypeScript
- Extract Method
- Extract Variable
- Inline Variable
- Rename Variable
To help boy-scout to clean the code.
- Extract Variable (
<LocalLeader>ev
) - Extract Method (
<LocalLeader>em
) - In-line Variable (
<LocalLeader>iv
) - Extract Property (
<LocalLeader>ep
)
- Rename Method (
<LocalLeader>rm
) - Rename Variable (
<LocalLeader>rv
) - Extract Constant (
<LocalLeader>ec
) - Rename Property (
<LocalLeader>rp
)
- Rename Directory (
<Leader>rd
, required github.com/phpactor/phpactor)
- Create Setters and Getters (
<LocalLeader>sg
) - Create only Getters (
<LocalLeader>cog
)
See ./doc/refactoring-toolbox.txt
- vim-plug:
Plug 'alquerci/vim-refactoring-toolbox'
- vundle:
Plugin 'alquerci/vim-refactoring-toolbox'
- pathogen:
git clone https://github.com/alquerci/vim-refactoring-toolbox.git ~/.vim/bundle/
bin/test