summaryrefslogtreecommitdiff
path: root/tools/repo2solv.sh
diff options
context:
space:
mode:
authorMichael Andres <ma@suse.de>2011-12-15 12:42:52 +0100
committerMichael Andres <ma@suse.de>2011-12-15 12:44:32 +0100
commit0b32498b989b051c90b8b685f0f520b80af42e93 (patch)
tree4fac4d10cd8dc7e0b53739d7335767d556ab8340 /tools/repo2solv.sh
parent06115c71523254cd62d084537d4fda62830c0151 (diff)
downloadlibsolv-0b32498b989b051c90b8b685f0f520b80af42e93.tar.gz
libsolv-0b32498b989b051c90b8b685f0f520b80af42e93.tar.bz2
libsolv-0b32498b989b051c90b8b685f0f520b80af42e93.zip
Also allow passing the repodata dir to repo2solv.sh.BASE-SuSE-Code-12_1-Branch
Diffstat (limited to 'tools/repo2solv.sh')
-rwxr-xr-xtools/repo2solv.sh6
1 files changed, 4 insertions, 2 deletions
diff --git a/tools/repo2solv.sh b/tools/repo2solv.sh
index 518f700..db1052c 100755
--- a/tools/repo2solv.sh
+++ b/tools/repo2solv.sh
@@ -98,7 +98,7 @@ cd "$dir" || exit 1
if test -z "$repotype" ; then
# autodetect repository type
- if test -d repodata ; then
+ if test -d repodata -o -f repomd.xml; then
repotype=rpmmd
elif test_susetags ; then
repotype=susetags
@@ -108,7 +108,9 @@ if test -z "$repotype" ; then
fi
if test "$repotype" = rpmmd ; then
- cd repodata || exit 2
+ test -d repodata && {
+ cd repodata || exit 2
+ }
primfile=
primxml=`repomd_findfile primary primary.xml`