我安装了 kubuntu-desktop 只是为了尝试一下它的界面。然后我决定删除它,并执行了传统的 apt-get purge 和 autoremove,但似乎 kubuntu 的元素仍然存在。例如界面元素、滚动条、启动屏幕等仍然存在。
有没有什么方法可以让我完全删除而无需安装全新的 ubuntu?
答案1
我建议您使用 aptitude 来执行此操作,这将搜索删除 KDE 环境并保留 Ubuntu 默认设置的软件包:
sudo apt-get install aptitude
aptitude search '?and(?and(?and(?reverse-depends(kubuntu),?not(?reverse-depends(ubuntu-desktop))),?automatic), ?not(?or(?priority(required), ?priority(important))))' ubuntu-desktop+
这将搜索任何kubuntu-desktop
依赖于 但不依赖于 的包ubuntu-desktop
。此外,这种方法有点贪婪。它将删除 Qt 包,因此 mplayer2、VLC 和任何依赖 Qt 库的软件包都可能被删除。在末尾添加带有加号 (+) 的软件包,例如本例中的 ubuntu-desktop 软件包。对于其他版本:
徐本图
aptitude search '?and(?and(?and(?reverse-depends(kubuntu),?not(?reverse-depends(xubuntu-desktop))),?automatic), ?not(?or(?priority(required), ?priority(important))))' xubuntu-desktop+
鲁本图
aptitude search '?and(?and(?and(?reverse-depends(kubuntu),?not(?reverse-depends(lubuntu-desktop))),?automatic), ?not(?or(?priority(required), ?priority(important))))' lubuntu-desktop+
侏儒
aptitude search '?and(?and(?and(?reverse-depends(kubuntu),?not(?reverse-depends(ubuntu-gnome-desktop))),?automatic), ?not(?or(?priority(required), ?priority(important))))' ubuntu-gnome-desktop+
如您所见,只需将最后一个软件包名称替换为您要保留的名称。如果您使用了kde-core
或其他元软件包,则应将“kubuntu”替换为元软件包的名称。
理解能力搜索
为了准确解释选择了哪个包,让我们更深入地解释搜索命令:
?and(
?and(
?and( // we're searching for packages that are
?reverse-depends(kubuntu), // reverse dependencies of kubuntu
?not(?reverse-depends(ubuntu-desktop)) // and not of ubuntu-desktop
), // that fulfills the condition above
?automatic // and is automatically installed
),
?not( // and also that are not
?or( // either required nor important
?priority(required),
?priority(important)
)
)
)
答案2
尝试从软件中心安装 Synaptic 包管理器。
或者直接在终端中输入:sudo apt-get install synaptic
安装并打开程序后,在部分选项卡中找到KDE 桌面环境部分并选择所有已安装的(绿色)选项(Ctrl + 单击)。然后右键单击,选择彻底清除和申请点击绿色复选标记在窗口顶部。
答案3
在 14.04 LTS 64 位中
sudo apt-get remove libkde3support4 k3b-data ntrack-module-libnl-0 libkrosscore4 libgpgme++2 libqapt2 oxygen-icon-theme libktexteditor4 libtaskmanager4abi5 kdenetwork-filesharing libkblog4 libchm1 plasma-widgets-addons libkimap4 plasma-netbook libkdeui5 libkdeclarative5 ttf-oxygen-font-family gtk3-engines-oxygen user-manager gpgsm libakonadi-kcal4 kdepim-kresources libruby1.9.1 plymouth-theme-kubuntu-logo libqt4-sql-mysql libmailtransport4 kde-telepathy-filetransfer-handler kde-zeroconf libkpimtextedit4 konsole liblastfm1 libqjson0 libtag-extras1 libkdecorations4abi1 libkdcraw23 libkpeople3 kdepimlibs-kio-plugins libqrencode3 libkparts4 libakonadiprotocolinternals1 libbalooxapian4 akonadi-server nepomuk-core-data libqca2 kubuntu-notification-helper kdemultimedia-kio-plugins libntrack0 kde-runtime-data cdparanoia libplasma-geolocation-interface4 quassel-data libkemoticons4 libmessagecomposer4 libweather-ion6 cdrdao libnepomukquery4a bluedevil libakonadi-notes4 libkmediaplayer4 libksieveui4 muon-discover libmicroblog4 libnetworkmanagerqt1 libqt4-qt3support libkcddb4 amarok-utils libmailcommon4 libktpcommoninternalsprivate7 libprocessui4a katepart libmusicbrainz5-0 libkwineffects1abi4 libreoffice-base libkdepim4 kaddressbook soprano-daemon libmessageviewer4 libkwinglesutils1 libsoprano4 libqapt2-runtime vcdimager libcln6 libvirtodbc0 libbaloopim4 okular libqca2-plugin-ossl libkonq5abi1 ubuntu-release-upgrader-qt python3-pyqt4 libkephal4abi1 libksba8 kdesudo libqoauth1 gnupg-agent libxerces-c3.1 kde-telepathy-data kdelibs5-plugins kcalc libqmobipocket1 systemsettings libkolabxml1 libsyndication4 libkjsapi4 libplasmagenericshell4 libksane0 libkprintutils4 knotes libkactivities6 libincidenceeditorsng4 lightdm-kde-greeter libreoffice-sdbc-firebird libiso9660-8 kubuntu-docs amarok gwenview libkcalcore4 virtuoso-opensource-6.1-common libkmbox4 virtuoso-opensource-6.1-bin libakonadi-contact4 libakonadi-socialutils4 plasma-widget-kimpanel kde-touchpad python3-dbus.mainloop.qt libqtscript4-gui python3-pykde4 plasma-widget-menubar libxcb-record0 libkcompactdisc4 kde-config-telepathy-accounts libkabc4 libkunitconversion4 okular-extra-backends plymouth-theme-kubuntu-text libcryptsetup4 ktorrent-data libknewstuff3-4 kde-workspace-kgreet-plugins kde-config-tablet gstreamer0.10-qapt akregator libxcb-xtest0 libnepomukutils4 odbcinst1debian2 kate libkmanagesieve4 libprocesscore4abi1 libqtscript4-network libksane-data ibus-qt4 ttf-dejavu-core libyaml-0-2 libkxmlrpcclient4 plasma-nm libpam-ck-connector libqgpgme1 print-manager libksignalplotter4 libkipi-data klipper libakonadi-kmime4 gtk2-engines-oxygen kde-telepathy-text-ui libkhtml5 libkcal4 libkmime4 ksysguardd kontact libmailimporter4 libakonadi-calendar4 libprison0 libsendlater4 libntrack-qt4-1 libsignon-qt1 libkldap4 libkfile4 kubuntu-settings-desktop libpoppler-qt4-4 kamera libbaloofiles4 libtelepathy-qt4-2 libnoteshared4 libakonadi-kde4 libreoffice-kde icoutils libgrantlee-gui0 socat libkdepimdbusinterfaces4 audiocd-kio libmodemmanagerqt1 liboath0 libmessagecore4 libqtglib-2.0-0 kde-baseapps-bin kubuntu-driver-manager libattica0.4 libmygpo-qt1 libkdesu5 libknewstuff2-4 dragonplayer libdlrestrictions1 libgps20 kde-telepathy-send-file libstreams0 libkidletime4 libkateinterfaces4 libknotifyconfig4 qapt-deb-installer libtemplateparser4 about-distro dolphin kinfocenter libplasmaclock4abi4 amarok-common kaccessible libqtscript4-uitools libxcb-composite0 libkcalutils4 libreoffice-java-common usb-creator-kde libkdecore5 kdelibs-bin plasma-desktop skanlite kmag kdegraphics-strigi-analyzer nepomuk-core-runtime plasma-scriptengine-javascript libperl4-corelibs-perl qapt-batch kde-wallpapers-default libloudmouth1-0 libqaccessibilityclient0 libktnef4 libflac++6 libnepomuk4 libkleo4 odbcinst pam-kwallet libstreamanalyzer0 libkdcraw-data docbook-xsl libkntlm4 libopenconnect2 software-properties-kde ktorrent krdc kmousetool kde-workspace-data libqtscript4-core partitionmanager cryptsetup libvcdinfo0 libboost-thread1.54.0 libkfbapi1 libxcb-damage0 ruby1.9.1 libkcmutils4 libkpimidentities4 libreoffice-style-oxygen k3b libkworkspace4abi2 colord-kde libkfilemetadata4 kde-style-oxygen libdebconf-kde0 libktorrent-l10n libpolkit-qt-1-1 libkolab0 libepub0 libkdgantt2-0 kubuntu-settings-netbook libqtscript4-xml kubuntu-web-shortcuts libtelepathy-logger-qt4-1 libkactivities-models1 libkpimutils4 freespacenotifier pinentry-qt4 kde-config-gtk-style libkgapi2-2 baloo libkubuntu0 python3-sip kmix libkio5 libxml2-utils ksnapshot libktorrent5 libakonadi-kabc4 libpimcommon4 kde-config-whoopsie libkpgp4 khelpcenter4 oxygen-cursor-theme shared-desktop-ontologies libkexiv2-data libplasma3 muon-updater kde-config-pimactivity kde-telepathy libaccounts-qt1 kdepasswd libqtscript4-sql libkexiv2-11 libkontactinterface4 libmessagelist4 kde-telepathy-integration-module kdepim-runtime libkscreen1 && sudo apt-get install ubuntu-desktop
答案4
这对我有用:
sudo apt-get install tasksel
sudo tasksel
寻找Kubuntu 桌面在列表中并删除其选择。阅读并确认提示。
此后我也这么做了
sudo apt-get autoremove