2 # @License EPL-1.0 <http://spdx.org/licenses/EPL-1.0>
3 ##############################################################################
4 # Copyright (c) 2016 The Linux Foundation and others.
6 # All rights reserved. This program and the accompanying materials
7 # are made available under the terms of the Eclipse Public License v1.0
8 # which accompanies this distribution, and is available at
9 # http://www.eclipse.org/legal/epl-v10.html
10 ##############################################################################
12 FILE_NAME=`echo $P2ZIP_URL | awk -F'/' '{ print $NF }'`
13 VERSION=`echo $P2ZIP_URL | awk -F'/' '{ print $(NF-1) }'`
15 wget $P2ZIP_URL -O $FILE_NAME
17 cat > ${WORKSPACE}/pom.xml <<EOF
18 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
19 <modelVersion>4.0.0</modelVersion>
20 <groupId>org.opendaylight.$PROJECT</groupId>
21 <artifactId>p2repo</artifactId>
22 <version>1.0.0-SNAPSHOT</version>
23 <packaging>pom</packaging>
28 <groupId>org.apache.maven.plugins</groupId>
29 <artifactId>maven-deploy-plugin</artifactId>
30 <version>2.8.2</version>
36 <groupId>org.sonatype.plugins</groupId>
37 <artifactId>maven-upload-plugin</artifactId>
38 <version>0.0.1</version>
44 <goal>upload-file</goal>
47 <serverId>opendaylight-p2</serverId>
48 <repositoryUrl>https://nexus.opendaylight.org/service/local/repositories/p2repos/content-compressed</repositoryUrl>
49 <file>$FILE_NAME</file>
50 <repositoryPath>org.opendaylight.$PROJECT/$VERSION</repositoryPath>