How to run a custom jar file copy to classpath command using java? -
i have jar file i'm using run application. however, every time run application need add -cp "jar name" compile , run java application.
how can make permanent change don't have use command line commands task? can put in lib location?
note: don't have use ide. has terminal.
if on linux/ mac, add following ~/.bash_profile
export classpath=$classpath:/path/to/jar
if on windows, use this..
set classpath=%classpath%;\path\to\jar
Comments
Post a Comment