[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

ANN: Java Project Environment, a simple way to manage multiple projects

This may be of interest to other *nix Java developers..


Here is a summary, from the docs:

 "[The JPE is] a simple system for working on multiple Java projects
 under GNU/Linux, in particular for managing project classpaths.
 One of the most painful aspects of Java programming, particularly for
 new programmers, is dealing with classpaths. Every project requires a
 set of jars, which must be listed in the $CLASSPATH variable before the
 project compiles or runs. Of course, every project requires a different
 set of jars. Since there is only one classpath, fixing it is a frequent
 A solution: nested shell-based environments

 The idea (and I'm sure it's pretty old..) is to start a new shell,
 inside your current one, when you start working on a project. The
 Subshell" can be customized in project-specific ways. Specifically,
 the $CLASSPATH variable is automatically populated with jars from
 certain directories (eg lib/), and directories containing classes (eg
 Here's what happens when one enters the project subshell:

   jeff@expresso:~$ cd myproj/
   jeff@expresso:~/myproj$ proj.sh 
    Java Project Environment: version 1.24, 2001/06/28 12:46:49
   Proj name:              My wonderful new project
   Proj alias:             myproj
   Proj author:            Jeff Turner
   Proj description:
   This fictitious project exists solely to illustrate the JPE
   Adding directories to classpath
           Adding /home/jeff/myproj/src
           Adding /home/jeff/myproj/src/java
   Loading jars from /home/jeff/myproj/lib
           Adding /home/jeff/myproj/lib/jaxp.jar
           Adding /home/jeff/myproj/lib/xalan.jar
           Adding /home/jeff/myproj/lib/xerces.jar
   Setting cdc alias to src/java/org/myco/myproj
   [jeff@expresso myproj ~]$ 
 When you start a project subshell:

    * The $HOME variable is reset to point to the project root.
    * The prompt ($PS1) is customized to include the project name.
    * jars from various predefined and user-specified directories are added to
      the classpath.
    * predefined and user-specified directories are added to the classpath (if
    * Project aliases are set up.

Hope someone finds it useful. I tend to jump between a lot of projects,
and it's has saved me quite a lot of time.


Reply to: