Eclim file browser Project Tree vs NerdTree

461 views
Skip to first unread message

Geeb

unread,
Nov 21, 2012, 10:03:12 AM11/21/12
to eclim...@googlegroups.com
Hi!
Firstly thanks for the Eclim project - I really appreciate being able to use the features of Eclipse and Vim simultaneously!

Here's my question:
I like the NerdTree tree browser more the Eclim's inbuilt Project Tree - essentially because it doesn't indent the sub-dir branches as much and use so much of the screen when deep in a dir structure. (My Java packages have long names!)

What I would like is a ":ProjectSelect myProj" command in eclim, that just focuses the window on the project (with tab completion for project names in the working dir) that works like :ProjectTab, but doesn't open the Project Tree, allowing me to fire up NerdTree instead.

Maybe there is a way of doing this already - please correct me if I'm missing something!

Thanks.

Eric Van Dewoestine

unread,
Nov 21, 2012, 10:15:18 AM11/21/12
to eclim...@googlegroups.com
On 2012-11-21 07:03:12, Geeb wrote:
> Hi!
> Firstly thanks for the Eclim project - I really appreciate being able to
> use the features of Eclipse and Vim simultaneously!
>
> Here's my question:
> I like the NerdTree <http://www.vim.org/scripts/script.php?script_id=1658> tree browser
> more the Eclim's inbuilt Project Tree - essentially because it doesn't
> indent the sub-dir branches as much and use so much of the screen when deep
> in a dir structure. (My Java packages have long names!)
>
> What I would like is a ":ProjectSelect myProj" command in eclim, that just
> focuses the window on the project (with tab completion for project names in
> the working dir) that works like :ProjectTab, but doesn't open the Project
> Tree, allowing me to fire up NerdTree instead.
>
> Maybe there is a way of doing this already - please correct me if I'm
> missing something!
>
> Thanks.
>

The latest version of eclim now has the ability to disable the auto
opening of the project tree when running :ProjectTab[1]

let g:EclimProjectTabTreeAutoOpen = 0

You can combine that with a custom command to auto open nerd tree
instead:

command -nargs=1 -bang
\ -complete=customlist,eclim#project#util#CommandCompleteProject
\ ProjectSelect :call <SID>ProjectSelect('<args>')
function s:ProjectSelect(project)
exec 'ProjectTab ' . a:project
NerdTree
endfunction

[1] http://eclim.org/vim/core/project.html#projecttab

--
eric

Geeb

unread,
Nov 21, 2012, 10:27:18 AM11/21/12
to eclim...@googlegroups.com
Awesome! Thanks.

John Reiter

unread,
Nov 21, 2012, 10:29:47 AM11/21/12
to eclim...@googlegroups.com
I prefer NerdTree as well.  My solution has been to use session.vim to save sessions, which will save the current directory in NerdTree, as well as any buffers you want to have open when you load the session later.

https://github.com/xolox/vim-session

John

--
You received this message because you are subscribed to the Google Groups "eclim-user" group.
To view this discussion on the web visit https://groups.google.com/d/msg/eclim-user/-/MCeFoXC-5ZAJ.
To post to this group, send email to eclim...@googlegroups.com.
To unsubscribe from this group, send email to eclim-user+...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/eclim-user?hl=en.

Reply all
Reply to author
Forward
0 new messages