Sublime Forum

Java CLASSPATH

#1

Is there a way to modify the java classpath in sublime text? I have appended a location to my .bashrc file. It all compiles fine in a terminal.

Using Ubuntu 10.10 with Build 2032 of Sublime Text 2.

0 Likes

#2

.bashrc is read by bash only, so unless you’ve started Sublime Text 2 from bash, the variable won’t be seen.

If you set the variable in .profile instead, then it should get picked up by the Display Manager, and thus inherited by Sublime Text 2 when it’s started. Take a look at help.ubuntu.com/community/EnvironmentVariables for more information.

You can check (and set, too) the values of the env vars from within Sublime Text 2 by using os.environ in the console:

import os
os.environ
0 Likes