本文介绍了dpkg:如何忽略 post/pre 脚本中的错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经开发了 debian 包并且在我的 post/pre 脚本(在我的例子中是 postrm)中有语法错误.我成功安装了包,但现在我无法删除这个包:

I've develop debian packages and have syntax mistake in my post/pre script (postrm in my case). I install package successfully, but now i can't remove this package :

/var/lib/dpkg/info/blablabla.postrm: 11: Syntax error: ";;" unexpected
dpkg: error processing blablabla (--remove):
 subprocess installed post-removal script returned error exit status 2

如何忽略它并完全删除包?

How can ignore it and completely remove package?

推荐答案

好吧,我个人对此也一无所知.如果 --force-all 不起作用,我只需编辑/var/lib/dpkg/info/blablabla.postrm 以使其正确.您正在删除软件包,所以不必担心很快会被删除的脚本,对吗?

Well, personally I have no idea about this either. If --force-all doesn't work, I would simply edit /var/lib/dpkg/info/blablabla.postrm to get it right. You're removing the package so won't be worried about the script which will be soon removed, will you?

这篇关于dpkg:如何忽略 post/pre 脚本中的错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

07-02 19:20