Did you ever have an error message similar to ‘unable to open file ‘/var/lib/dpkg/tmp.ci//.svn’: Is a directory’?
Here is a way to fix it:
Open up a Terminal window, and type in it:
export DEBPATH=path/to/bad/debfile.deb
Then copy and paste this into it:
sudo apt-add-repository ppa:lkjoel/deb-extract
sudo apt-get update
sudo apt-get install deb-extract dpkg-dev
sudo deb-extract $DEBPATH `basename $DEBPATH .deb`
cd `basename $DEBPATH .deb`
cat < svnemfix.sh
#!/bin/bash
# SVN Emergency Fix
function rdirls() {
for i in $1/*
do
if [ -d "$i" ]
then
echo $i
rm -rf $i/.svn
rdirls $i
else
echo "NOT $i" > /dev/null 2>&1
fi
done
}
if [ -d "$1" ]
then
echo $1
rm -rf $1/.svn
rdirls $1
fi
EOF
chmod +x svnemfix.sh
./svnemfix.sh .
rm -f svnemfix.sh
cd ..
sudo dpkg-deb -b `basename $DEBPATH .deb`
Like this:
Be the first to like this post.