一个shell脚本例子

#!/bin/sh

jarlist=$(ls/home/hp/servers/apache-flume-1.5.2-bin/lib/*.jar)

CLASSPATH=/home/hp/projects/flume-test/target/flume-test-1.0.jar

forjarin${jarlist}

do

CLASSPATH=${CLASSPATH}:${jar}

done

echo${CLASSPATH}

java-classpath$CLASSPATHper.flume.WriteLog

相关推荐