由於 dartvm 無法安裝新軟體?

由於 dartvm 無法安裝新軟體?

我最近嘗試運行此命令來安裝 dart vm:

$ sudo apt-get update
$ sudo apt-get install apt-transport-https
# Get the Google Linux package signing key.
$ sudo sh -c 'curl https://dl-ssl.google.com/linux/linux_signing_key.pub | apt-key add -'
# Set up the location of the stable repository.
$ sudo sh -c 'curl https://storage.googleapis.com/download.dartlang.org/linux/debian/dart_stable.list > /etc/apt/sources.list.d/dart_stable.list'
$ sudo apt-get update

但這不會安裝 IDE 或 Dartium,所以我執行了以下命令:

$ sudo add-apt-repository ppa:hachre/dart
$ sudo apt-get update
$ sudo apt-get install darteditor

但現在當我嘗試使用終端安裝任何東西時出現此錯誤:

You might want to run 'apt-get -f install' to correct these:
The following packages have unmet dependencies:
dartsdk : Depends: dartvm (>= 0.5.0.1+r21823-3) but it is not going to be installed
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).

我嘗試運行這個來修復它:

sudo apt-get -f remove 
sudo apt-get autoremove
sudo apt-get autoclean 
sudo apt-get remove dartvm
sudo apt-get remove darteditor
sudo apt-get remove dartsdk

我無法安裝 ppa-purge,並且無法刪除先前的軟體包而不出現相同的錯誤。有人可以幫忙嗎?

答案1

修復它這樣做:

sudo dpkg --purge dartsdk
sudo apt-get update

此後一切正常。

相關內容