<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -46,6 +46,9 @@ HUDSON_IS_DAEMON=&quot;true&quot;
 ## the SSL KeyManagerFactory type (eg SunX509, IbmX509). Default is SunX509
 #HUDSON_HTTPS_KEY_MANAGER=&quot;SunX509&quot;
 
+## Default home of hudson stuffs
+#HUDSON_HOME=/var/lib/hudson
+
 ## Default location to log
 #HUDSON_LOG_DIR=/var/log/hudson.log 
 
@@ -55,3 +58,5 @@ HUDSON_IS_DAEMON=&quot;true&quot;
 ## set document root folder
 #HUDSON_WEBROOT=/var/lib/hudson/webroot
 
+## any additionally flags available, see `hudson --help`
+#OPT_ARGS=&quot;&quot;</diff>
      <filename>projects/hudson/etc/hudson.conf</filename>
    </modified>
    <modified>
      <diff>@@ -35,37 +35,37 @@ elif [ &quot;$ARCH&quot; = &quot;x86_64&quot; ]; then
   SLKCFLAGS=&quot;-O2 -fPIC&quot;
 fi
 
-set -e # Exit on most errors
+set -e
 
-VERSION=$(unzip -p hudson.war  META-INF/maven/org.jvnet.hudson.main/hudson-war/pom.properties | grep -e '^version' | cut -d = -f 2)
+VERSION=$(unzip -p $PRGNAM.war  META-INF/maven/org.jvnet.$PRGNAM.main/$PRGNAM-war/pom.properties | grep -e '^version' | cut -d = -f 2)
 
 rm -rf $PKG
 mkdir -p $TMP $PKG $OUTPUT
 cd $TMP
 
-mkdir -p $PKG/usr/lib/hudson
-cp -av $CWD/hudson.war $PKG/usr/lib/hudson/
+mkdir -p $PKG/opt/$PRGNAM
+cp -av $CWD/$PRGNAM.war $PKG/opt/$PRGNAM
 
 mkdir -p $PKG/usr/bin
-cat $CWD/hudsond.sh &gt; $PKG/usr/bin/hudsond
-chmod +x $PKG/usr/bin/hudsond
+cat $CWD/${PRGNAM}d.sh &gt; $PKG/usr/bin/${PRGNAM}d
+chmod +x $PKG/usr/bin/${PRGNAM}d
 
-cat &gt; $PKG/usr/bin/hudson &lt;&lt; EOF
+cat &gt; $PKG/usr/bin/$PRGNAM &lt;&lt; EOF
 #!/bin/sh
 
-java -jar /usr/lib$LIBDIRSUFFIX/hudson/hudson.war \${1+&quot;\$@&quot;}
+java -jar /opt/$PRGNAM/$PRGNAM.war \${1+&quot;\$@&quot;}
 
 EOF
-chmod +x $PKG/usr/bin/hudson
+chmod +x $PKG/usr/bin/$PRGNAM
 
 mkdir -p $PKG/etc/rc.d
 mkdir -p $PKG/etc/logrotate.d
-cat $CWD/etc/rc.hudson &gt; $PKG/etc/rc.d/rc.hudson.new
-cat $CWD/etc/hudson.conf &gt; $PKG/etc/hudson.conf.new
-cat $CWD/etc/hudson-logrotate &gt; $PKG/etc/logrotate.d/hudson
+cat $CWD/etc/rc.$PRGNAM &gt; $PKG/etc/rc.d/rc.$PRGNAM.new
+cat $CWD/etc/$PRGNAM.conf &gt; $PKG/etc/$PRGNAM.conf.new
+cat $CWD/etc/$PRGNAM-logrotate &gt; $PKG/etc/logrotate.d/$PRGNAM
 
 mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
-java -jar $CWD/hudson.war --help &gt; $PKG/usr/doc/$PRGNAM-$VERSION/HELP.txt
+java -jar $CWD/$PRGNAM.war --help &gt; $PKG/usr/doc/$PRGNAM-$VERSION/HELP.txt
 cat $CWD/$PRGNAM.SlackBuild &gt; $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
 
 mkdir -p $PKG/install</diff>
      <filename>projects/hudson/hudson.SlackBuild</filename>
    </modified>
    <modified>
      <diff>@@ -5,11 +5,12 @@
 
 JAVA=$(which java)
 PIDFILE=&quot;/var/run/hudson.pid&quot;
-HUDSON=&quot;/usr/lib/hudson/hudson.war&quot;
+HUDSON=&quot;/opt/hudson/hudson.war&quot;
 HUDSON_HTTP_PORT=&quot;8080&quot;
 HUDSON_LOG_FILE=&quot;/var/log/hudson.log&quot;
 HUDSON_WEBAPPSDIR=&quot;/var/lib/hudson/apps/&quot;
 HUDSON_WEBROOT=&quot;/var/lib/hudson/webroot/&quot;
+OPT_ARGS=&quot;&quot;
 export HUDSON_HOME=&quot;/var/lib/hudson&quot;
 
 if [ &quot;$UID&quot; -ne 0 ] ; then
@@ -17,7 +18,7 @@ if [ &quot;$UID&quot; -ne 0 ] ; then
   exit 1
 fi
 
-PREV_PID=$( pgrep -f &quot;/usr/lib/hudson/hudson.war&quot; )
+PREV_PID=$( pgrep -f &quot;/opt/hudson/hudson.war&quot; )
 if [ ! &quot;$PREV_PID&quot; = &quot;&quot; ] ; then
   echo $PREV_PID still running
   exit 1
@@ -86,7 +87,8 @@ $JAVA -jar $HUDSON \
   $HUDSON_HTTPS_KEY_MANAGER_ARG \
   $HUDSON_LOG_FILE_ARG \
   $HUDSON_WEBAPPSDIR_ARG \
+  $OPT_ARGS \
   $HUDSON_WEBROOT_ARG &amp;
 
-pgrep -f &quot;/usr/lib/hudson/hudson.war&quot; &gt; $PIDFILE
+pgrep -f &quot;/opt/hudson/hudson.war&quot; &gt; $PIDFILE
 </diff>
      <filename>projects/hudson/hudsond.sh</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>3cccb5530ed7bd123900d2e37d80c0c42717e1d2</id>
    </parent>
  </parents>
  <author>
    <name>Vincent Batts</name>
    <email>vbatts@spiderpig.awarix.com</email>
  </author>
  <url>http://github.com/vbatts/SlackBuilds/commit/63978a759e06e0abde5581d25b8eb8f8d4e43b3a</url>
  <id>63978a759e06e0abde5581d25b8eb8f8d4e43b3a</id>
  <committed-date>2009-10-23T21:12:27-07:00</committed-date>
  <authored-date>2009-10-23T21:12:27-07:00</authored-date>
  <message>Fri Oct 16 04:37:44 CDT 2009

* add to the `hudsond` and *.conf an OPTS ability to pass any additional --flags over and above the ENVIRONMENTS_VARIABLES availible
* include HUDSON_HOME in the *.conf</message>
  <tree>df82dd32e3b9da2b8e09da016829f6b3fb977087</tree>
  <committer>
    <name>Vincent Batts</name>
    <email>vbatts@spiderpig.awarix.com</email>
  </committer>
</commit>
