Virtual Project Tree Plugin

Shad Stafford
VirtualProjectTree@techshadow.com

Introduction

This plugin grew out of my frustration with traditional project viewers, I'm a visual person and have grown accustomed to using a tree view of files in my project but many project viewers force the tree view to map directly to the filesystem structure which does not always map to the way I think things should be organized. I wanted a way to have my tree differ (even if only slightly) from the structure on disk.

Virtual Project Tree allows you to create an arbitrary tree of directories and files. Each file and directory added to the tree must exist on disk, but you can arrange them however you want within the tree. I find this particularly useful when I am working on a project with a long package hierarchy that I don't want cluttering up my tree or if I'm working on a project that pulls in source files from multiple locations.

Features

Usage

Once you've installed the package, choose the "Virtual Project Tree" item from the "Plugins" menu. You have the option of docking the window or keeping it as a floating window, and everything should work the same regardless of which you choose. Right click in the VPT window to create a new project. After you have specified the project name, right click on the project and choose "Add File", "Add Directory", or "Add Directory Tree" to start adding files to your project. If you choose "Add Directory Tree" it will add the directory you select and all its subdirectories and files. Note that it will use the filter that you specify in the file chooser, only adding files that match the filter. Once you have added files to your project you can open them by single clicking on them or perform some actions by right clicking on them.

Showing tool tips

There is an option to show tool tips in the tree view. When this option is selected and you click on a partially obscured filename in the tree view, a tooltip will display the full name of the file.

Examining jar contents

When you right click on a file with the extension ".jar", a menu item "Show Contents" is added to the popup menu. This item opens a new untitled buffer containing a listing of the contents of the jar file (similar to doing a "-t" option in the jar tool).

Executing ant tasks

When you right click on a file with the extension ".xml", the file is examined to see if it appears to be an ant build file (if it has a root element "project"). If it is an ant build file, menu items are added for each target in the build file. Clicking on a target will attempt to execute it using antfarm. If antfarm is not installed, the targets will still appear but clicking on them will just bring up an error dialog. There is an option to filter the tasks which causes only those tasks with descriptions to be displayed. This works similar to the way the "-projecthelp" option works in ant so if you have targets that are not meant to be executed directly you can hide them by not specifying a description.

Bugs

There are currently no known bugs.

Change History

1.0.1

Acknowledgements

Many thanks to Jon Dalberg for providing the code for the antfarm integration and jar contents feature.

License

The Virtual Project Tree Plugin is licensed under the GNU General Public License and comes with ABSOLUTELY NO WARRANTY; for details see the full license. This is free software, and you are welcome to redistribute it under the terms and conditions described in the license.

 

 

Version: 1.0.1 --- Built: 2002/12/08