You are viewing a plain text version of this content. The canonical link for it is here.
Posted to m2-dev@maven.apache.org by ca...@apache.org on 2004/09/02 22:15:36 UTC

cvs commit: maven-components/maven-meeper/src/bin deploy-bundle

carlos      2004/09/02 13:15:36

  Modified:    maven-meeper/src/bin deploy-bundle
  Log:
  the parameter is now the bundle url and copies files to repository dir to be sync'ed later
  
  Revision  Changes    Path
  1.7       +25 -10    maven-components/maven-meeper/src/bin/deploy-bundle
  
  Index: deploy-bundle
  ===================================================================
  RCS file: /home/cvs/maven-components/maven-meeper/src/bin/deploy-bundle,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- deploy-bundle	16 Jun 2004 12:39:12 -0000	1.6
  +++ deploy-bundle	2 Sep 2004 20:15:36 -0000	1.7
  @@ -1,24 +1,31 @@
   #!/bin/sh
   
  -BUNDLE=$1
  +BUNDLEURL=$1
   VERSION=$2
   
  -[ "${BUNDLE}" = "" ] && echo && echo "You must specify a bundle!" && echo && exit
  +[ "${BUNDLEURL}" = "" ] && echo && echo "You must specify a bundle URL!" && echo && exit
   
   WORKDIR=bundle.tmp
  +# repo dir relative to WORKDIR
  +REPODIR=../repository
   
   rm -rf $WORKDIR > /dev/null 2>&1
   
   mkdir $WORKDIR
   
  -cp $BUNDLE $WORKDIR
  +cd $WORKDIR
  +
  +wget $BUNDLEURL
  +BUNDLE=`echo $BUNDLEURL | sed -e 's#^.*/##;'`
  +
  +echo $BUNDLE
   
   (
  -  cd $WORKDIR
   
     jar xf $BUNDLE
   
     POM=project.xml
  +  less $POM
   
     ../d2u ${POM}
   
  @@ -60,6 +67,10 @@
     echo "artifactId: [${artifactId}]"
     echo
   
  +  echo
  +  echo -n Hit Enter to continue or Ctrl-C to abort...
  +  read
  +
     LIC=LICENSE.txt
   
     # A little help for manually created upload bundles
  @@ -72,18 +83,22 @@
   
     ../d2u $LIC
   
  -  ../deploy-lic $LIC ${groupId}
  -  
  -  ../deploy-pom ${artifactId}-${version}.pom ${groupId}
  -  
  +  mkdir -p $REPODIR/${groupId}/licenses
  +  cp $LIC $REPODIR/${groupId}/licenses/${artifactId}-${version}.license  
  +
  +  mkdir -p $REPODIR/${groupId}/poms
  +  cp ${artifactId}-${version}.pom $REPODIR/${groupId}/poms
  +
     artifactType=`echo ${artifactId} | sed -e 's/maven-.*-plugin//'`
     
     if [ -z ${artifactType} ]
     then
       echo "Deploying Plugin ..."
  -    ../deploy-plugin ${artifactId}-${version}.jar ${groupId}        
  +     mkdir -p $REPODIR/${groupId}/plugins
  +     cp ${artifactId}-${version}.jar $REPODIR/${groupId}/plugins
     else
       echo "Deploying JAR ..."
  -    ../deploy-jar ${artifactId}-${version}.jar ${groupId}        
  +    mkdir -p $REPODIR/${groupId}/jars
  +    cp ${artifactId}-${version}.jar $REPODIR/${groupId}/jars
     fi    
   )