From: sthen Date: Wed, 5 Apr 2017 11:57:58 +0000 (+0000) Subject: For a non-interactive attempt to pkg_delete a firmware package, print a X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=090fc76712e5ccdc82fc35b71207db35da2f032b;p=openbsd For a non-interactive attempt to pkg_delete a firmware package, print a message advising use of "fw_update -d" rather than saying "ok" and doing nothing. (pkg_delete intentionally makes it hard to uninstall firmware to prevent surprises when cleaning a machine). aja and I were surprised by the "ok" leaving the fw package installed. suggestion from espie to mention fw_update -d in the message. --- diff --git a/usr.sbin/pkg_add/OpenBSD/Delete.pm b/usr.sbin/pkg_add/OpenBSD/Delete.pm index 94faf84a713..9a5bcd7eba7 100644 --- a/usr.sbin/pkg_add/OpenBSD/Delete.pm +++ b/usr.sbin/pkg_add/OpenBSD/Delete.pm @@ -1,5 +1,5 @@ # ex:ts=8 sw=4: -# $OpenBSD: Delete.pm,v 1.148 2017/03/25 18:58:59 espie Exp $ +# $OpenBSD: Delete.pm,v 1.149 2017/04/05 11:57:58 sthen Exp $ # # Copyright (c) 2003-2014 Marc Espie # @@ -100,6 +100,7 @@ sub delete_package return; } } else { + $state->errsay("NOT deleting #1: use fwupdate -d", $pkgname); return; } }