¿Cómo puedo eliminar o reinstalar un programa después de haber eliminado accidentalmente su carpeta de instalación?
Accidentalmente eliminé /opt/spotify/
carpeta y no puedo reinstalar spotify-client
ni purgarlo.
sudo apt-get purge spotify-client
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be REMOVED:
spotify-client*
0 upgraded, 0 newly installed, 1 to remove and 45 not upgraded.
1 not fully installed or removed.
After this operation, 143 MB disk space will be freed.
Do you want to continue? [Y/n]
(Reading database ... 276312 files and directories currently installed.)
Removing spotify-client (1:0.9.17.1.g9b85d43.7-1) ...
/var/lib/dpkg/info/spotify-client.prerm: 9: cd: can't cd to /opt/spotify/spotify-client
dpkg: error processing package spotify-client (--purge):
subprocess installed pre-removal script returned error exit status 2
/var/lib/dpkg/info/spotify-client.postinst: 5: cd: can't cd to /opt/spotify/spotify-client
dpkg: error while cleaning up:
subprocess installed post-installation script returned error exit status 2
Errors were encountered while processing:
spotify-client
E: Sub-process /usr/bin/dpkg returned an error code (1)
y
sudo apt-get install --reinstall spotify-client
Reading package lists... Done
Building dependency tree
Reading state information... Done
0 upgraded, 0 newly installed, 1 reinstalled, 0 to remove and 45 not upgraded.
1 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
E: Internal Error, No file name for spotify-client:amd64
Por supuesto, ¡la carpeta no está en la basura! Gracias.
0 votos
Crear manualmente el directorio
/opt/spotify/spotify-client
y luego tratar de purgar. A ver qué pasa1 votos
No funciona, el mismo problema (¡busca cosas dentro de la nueva carpeta vacía!)
0 votos
Lo que ocurre con
sudo apt-get install spotify-client
?0 votos
Exactamente el mismo mensaje que escribí en la pregunta principal