-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathcommon.sh
More file actions
executable file
·20 lines (18 loc) · 819 Bytes
/
common.sh
File metadata and controls
executable file
·20 lines (18 loc) · 819 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#! /bin/bash
function setup_home () {
eclipse_home=$(dirname $(readlink -f $(which eclipse)))
if [ -z ${eclipse_home} ]; then
echo "Failed to locate the Eclipse Home directory."
exit 0
fi
osgiJar=$(find ${eclipse_home} -name "org.eclipse.osgi_*.jar" 2>/dev/null | head -1)
}
function setup_jar () {
p2qJar=$(find /usr/share/java/ /opt/ $HOME/git/utils-for-eclipse -name "com.github.utils4e*.jar" 2>/dev/null | head -1)
fpp2Jar=$(find /usr/share/java/ /opt/ $HOME/git/fedoraproject-p2 -name "org.fedoraproject.p2-*.jar" 2>/dev/null | head -1)
slf4jApiJar=$(find ${eclipse_home} /usr/share/java/ /opt/ $HOME/.m2 -name "slf4j-api-2.*.jar" -or -name "slf4j.api_2.*" 2>/dev/null | grep -v sources | head -1)
if [ -z ${p2qJar} ]; then
echo "Failed to locate the p2 Query Jar."
exit 0
fi
}