Re: apt-get where are the files stored?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Jeff Allison wrote:
/var/cache/apt/archives/


You may also notice that the files do not have names that you would expect. I have included a script that was posted on the freshrpms list and that renames the files to the correct name.

Just do:
aptclean *.rpm

Serge
#!/bin/bash
##############################################################################
# Turn an apt format rpm name into a real one
# Author: Chris Rouch
# Date: 04/06/02
# Changelog:
##############################################################################
FMT="%{NAME}-%{VERSION}-%{RELEASE}.%{ARCH}.rpm"
rpms=$*

for file in $rpms; do
    real=`rpm -qp --queryformat="$FMT\n" $file`
    dir=`dirname $file`
    echo $dir/$real
    if [ "$file" == "$dir/$real" ]; then
	echo "no change for $file"
	continue
    fi
    mv $file $dir/$real
done

[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux