Remove obsolete files

This commit is contained in:
Marek Marczykowski 2013-03-14 14:24:12 +01:00
parent 820ee45f03
commit e1472df9dd
4 changed files with 0 additions and 96 deletions

View File

@ -1,14 +0,0 @@
#!/bin/sh
if grep -q X-Qubes-VmName $1 ; then
exit 0
fi
if grep -q "Categories=.*\(System\|Settings\)" $1 ; then
#echo "Leaving file: $1"
exit 0
fi
BACKUP_DIR="/var/lib/qubes/backup/removed-apps/"
mkdir -p $BACKUP_DIR
#echo "Moving file: $1 to $BACKUP_DIR
mv $1 $BACKUP_DIR

View File

@ -1,6 +0,0 @@
#!/bin/sh
echo "--> Removing unnecessary Dom0 Appmenus..."
find /usr/share/applications -name *.desktop -exec /usr/lib/qubes/check_and_remove_appmenu.sh {} \;
xdg-desktop-menu forceupdate

View File

@ -1,74 +0,0 @@
#!/usr/bin/python2
#
# The Qubes OS Project, http://www.qubes-os.org
#
# Copyright (C) 2010 Joanna Rutkowska <joanna@invisiblethingslab.com>
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#
#
from optparse import OptionParser
import subprocess
import shutil
import re
def find_net_devices():
p = subprocess.Popen (["lspci", "-mm", "-n"], stdout=subprocess.PIPE)
result = p.communicate()
retcode = p.returncode
if (retcode != 0):
print "ERROR when executing lspci!"
raise IOError
net_devices = set()
rx_netdev = re.compile (r"^([0-9a-f][0-9a-f]:[0-9a-f][0-9a-f].[0-9]) \"02")
for dev in str(result[0]).splitlines():
match = rx_netdev.match (dev)
if match is not None:
dev_bdf = match.group(1)
assert dev_bdf is not None
net_devices.add (dev_bdf)
return net_devices
def main():
usage = "usage: %prog [options] <netvm-name>"
parser = OptionParser (usage)
parser.add_option ("-v", "--verbose", dest="verbose", action="store_true", default=False)
(options, args) = parser.parse_args ()
if options.verbose:
print "Loading Xen PCI Backend..."
retcode = subprocess.call (["/sbin/modprobe", "pciback"])
if retcode != 0:
print "ERROR: Cannot load the pciback module!"
exit(1)
if options.verbose:
print "Unbinding the following net devices:"
net_devices = find_net_devices()
for dev in net_devices:
if options.verbose:
print "--> {0}".format(dev)
retcode = subprocess.call (["/usr/lib/qubes/unbind_pci_device.sh", dev])
if (retcode != 0):
print "WARNING: Could not unbind device {0}".format(dev)
main()

View File

@ -124,7 +124,6 @@ cp qmemman/qmemman.conf $RPM_BUILD_ROOT%{_sysconfdir}/qubes/
mkdir -p $RPM_BUILD_ROOT/usr/lib/qubes
cp aux-tools/unbind_pci_device.sh $RPM_BUILD_ROOT/usr/lib/qubes
cp aux-tools/unbind_all_network_devices $RPM_BUILD_ROOT/usr/lib/qubes
cp aux-tools/convert_apptemplate2vm.sh $RPM_BUILD_ROOT/usr/lib/qubes
cp aux-tools/convert_dirtemplate2vm.sh $RPM_BUILD_ROOT/usr/lib/qubes
cp aux-tools/create_apps_for_appvm.sh $RPM_BUILD_ROOT/usr/lib/qubes
@ -364,7 +363,6 @@ fi
%{python_sitearch}/qubes/__init__.pyo
%{python_sitearch}/qubes/qmemman*.py*
/usr/lib/qubes/unbind_pci_device.sh
/usr/lib/qubes/unbind_all_network_devices
/usr/lib/qubes/cleanup_dispvms
/usr/lib/qubes/convert_apptemplate2vm.sh
/usr/lib/qubes/convert_dirtemplate2vm.sh