linux bash:
YOUR_LIB=your_path
for jar in `ls $YOUR_LIB/*.jar`
do
CLASSPATH="$CLASSPATH:""$jar"
done
windows :
SETLOCAL ENABLEDELAYEDEXPANSION
set LIB=xx
set CLASSPATH=.
FOR %%C IN (LIB*.jar) DO set CLASSPATH=!CLASSPATH!;%%C
echo %CLASSPATH%
时间: 2024-11-02 20:32:01