Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 17 additions & 14 deletions doc/phpactor.txt
Original file line number Diff line number Diff line change
Expand Up @@ -191,20 +191,23 @@ Phpactor does not assume any mappings automatically, the following mappings
are available for you to copy:
>

nmap <Leader>u :PhpactorImportClass<CR>
nmap <Leader>ua :PhpactorImportAllClasses<CR>
Comment thread
yaegassy marked this conversation as resolved.
Resolved
nmap <Leader>mm :PhpactorContextMenu()<CR>
nmap <Leader>nn :PhpactorNavigate()<CR>
nmap <Leader>oo :PhpactorGotoDefinition()<CR>
nmap <Leader>oh :PhpactorGotoDefinitionHsplit()<CR>
nmap <Leader>ov :PhpactorGotoDefinitionVsplit()<CR>
nmap <Leader>ot :PhpactorGotoDefinitionTab()<CR>
nmap <Leader>K :PhpactorHover()<CR>
nmap <Leader>tt :PhpactorTransform()<CR>
nmap <Leader>cc :PhpactorClassNew()<CR>
nmap <silent><Leader>ee :PhpactorExtractExpression(v:false)<CR>
vmap <silent><Leader>ee :<C-U>PhpactorExtractExpression(v:true)<CR>
vmap <silent><Leader>em :<C-U>PhpactorExtractMethod()<CR>
augroup PhpactorMappings
Comment thread
yaegassy marked this conversation as resolved.
Resolved
Comment thread
yaegassy marked this conversation as resolved.
Resolved
au!
au FileType php nmap <buffer> <Leader>u :PhpactorImportClass<CR>
au FileType php nmap <buffer> <Leader>ua :PhpactorImportMissingClasses<CR>
au FileType php nmap <buffer> <Leader>mm :PhpactorContextMenu<CR>
au FileType php nmap <buffer> <Leader>nn :PhpactorNavigate<CR>
au FileType php nmap <buffer> <Leader>oo :PhpactorGotoDefinition<CR>
au FileType php nmap <buffer> <Leader>oh :PhpactorGotoDefinitionHsplit<CR>
au FileType php nmap <buffer> <Leader>ov :PhpactorGotoDefinitionVsplit<CR>
au FileType php nmap <buffer> <Leader>ot :PhpactorGotoDefinitionTab<CR>
au FileType php nmap <buffer> <Leader>K :PhpactorHover<CR>
au FileType php nmap <buffer> <Leader>tt :PhpactorTransform<CR>
au FileType php nmap <buffer> <Leader>cc :PhpactorClassNew<CR>
au FileType php nmap <buffer> <silent> <Leader>ee :PhpactorExtractExpression<CR>
au FileType php vmap <buffer> <silent> <Leader>ee :<C-u>PhpactorExtractExpression<CR>
au FileType php vmap <buffer> <silent> <Leader>em :<C-u>PhpactorExtractMethod<CR>
augroup END
<


Expand Down
6 changes: 5 additions & 1 deletion ftplugin/php/commands.vim
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ command! -nargs=0 PhpactorFindReferences call phpactor#FindReferences()
""
" Navigate - jump to the parent class, interface, or any of the relationships
" defined in `navigation.destinations` https://phpactor.github.io/phpactor/configuration.html#reference
command! -nargs=0 PhpactorNavigate call phpactor#Naviagate()
command! -nargs=0 PhpactorNavigate call phpactor#Navigate()

""
" Rotate the visiblity of the method under the cursor
Expand All @@ -124,3 +124,7 @@ command! -nargs=0 PhpactorChangeVisibility call phpactor#ChangeVisibility()
""
" Generate accessors for the current class
command! -nargs=0 PhpactorGenerateAccessors call phpactor#GenerateAccessors()

""
" Automatically add any missing properties to a class
command! -nargs=0 PhpactorTransform call phpactor#Transform()
31 changes: 17 additions & 14 deletions ftplugin/php/mappings.vim
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,22 @@
" Phpactor does not assume any mappings automatically, the following mappings
" are available for you to copy: >
"
" nmap <Leader>u :PhpactorImportClass<CR>
" nmap <Leader>ua :PhpactorImportAllClasses<CR>
" nmap <Leader>mm :PhpactorContextMenu()<CR>
" nmap <Leader>nn :PhpactorNavigate()<CR>
" nmap <Leader>oo :PhpactorGotoDefinition()<CR>
" nmap <Leader>oh :PhpactorGotoDefinitionHsplit()<CR>
" nmap <Leader>ov :PhpactorGotoDefinitionVsplit()<CR>
" nmap <Leader>ot :PhpactorGotoDefinitionTab()<CR>
" nmap <Leader>K :PhpactorHover()<CR>
" nmap <Leader>tt :PhpactorTransform()<CR>
" nmap <Leader>cc :PhpactorClassNew()<CR>
" nmap <silent><Leader>ee :PhpactorExtractExpression(v:false)<CR>
" vmap <silent><Leader>ee :<C-U>PhpactorExtractExpression(v:true)<CR>
" vmap <silent><Leader>em :<C-U>PhpactorExtractMethod()<CR>
" augroup PhpactorMappings
" au!
" au FileType php nmap <buffer> <Leader>u :PhpactorImportClass<CR>
" au FileType php nmap <buffer> <Leader>ua :PhpactorImportMissingClasses<CR>
" au FileType php nmap <buffer> <Leader>mm :PhpactorContextMenu<CR>
" au FileType php nmap <buffer> <Leader>nn :PhpactorNavigate<CR>
" au FileType php nmap <buffer> <Leader>oo :PhpactorGotoDefinition<CR>
" au FileType php nmap <buffer> <Leader>oh :PhpactorGotoDefinitionHsplit<CR>
" au FileType php nmap <buffer> <Leader>ov :PhpactorGotoDefinitionVsplit<CR>
" au FileType php nmap <buffer> <Leader>ot :PhpactorGotoDefinitionTab<CR>
" au FileType php nmap <buffer> <Leader>K :PhpactorHover<CR>
" au FileType php nmap <buffer> <Leader>tt :PhpactorTransform<CR>
" au FileType php nmap <buffer> <Leader>cc :PhpactorClassNew<CR>
" au FileType php nmap <buffer> <silent> <Leader>ee :PhpactorExtractExpression<CR>
" au FileType php vmap <buffer> <silent> <Leader>ee :<C-u>PhpactorExtractExpression<CR>
" au FileType php vmap <buffer> <silent> <Leader>em :<C-u>PhpactorExtractMethod<CR>
" augroup END
" <
"