3 # Copyright © 2019 Red Hat, Inc. and others.
5 # This program and the accompanying materials are made available under the
6 # terms of the Eclipse Public License v1.0 which accompanies this distribution,
7 # and is available at http://www.eclipse.org/legal/epl-v10.html
10 echo "Usage: $0 <project> <current version> <target version>"
11 echo "Bumps all dependencies on the given project from <current version>"
12 echo "to <target version>."
13 echo "E.g. $0 odlparent 3.0.2 3.1.0-SNAPSHOT"
21 # We use find/grep instead of git grep to allow running this on
22 # multiple repositories
23 for file in $(find . -type f -name pom.xml | xargs grep -l ${curver})
25 echo -n Processing ${file}...
26 xmlstarlet ed -P -L -N mvn=http://maven.apache.org/POM/4.0.0 -u //mvn:version[../mvn:groupId=\"org.opendaylight.${project}\"] -v ${target} ${file}