summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarc Espie <espie@cvs.openbsd.org>2010-01-01 13:36:08 +0000
committerMarc Espie <espie@cvs.openbsd.org>2010-01-01 13:36:08 +0000
commite59d685aaf7437f5be2cdfab00c0fba50557809e (patch)
tree98eb8276d46d949d9e6151f21408db37ba391c8e
parentfa13a2ae8fb9431b3d8bce588a58129d5e23917a (diff)
new option 'explicit-update', for firmwares (don't consider these in bulk
updates, only when user asks for them explicitly)
-rw-r--r--usr.sbin/pkg_add/OpenBSD/PackingElement.pm13
-rw-r--r--usr.sbin/pkg_add/OpenBSD/PackingList.pm6
2 files changed, 14 insertions, 5 deletions
diff --git a/usr.sbin/pkg_add/OpenBSD/PackingElement.pm b/usr.sbin/pkg_add/OpenBSD/PackingElement.pm
index 2b6e32923c3..40346793d21 100644
--- a/usr.sbin/pkg_add/OpenBSD/PackingElement.pm
+++ b/usr.sbin/pkg_add/OpenBSD/PackingElement.pm
@@ -1,7 +1,7 @@
# ex:ts=8 sw=4:
-# $OpenBSD: PackingElement.pm,v 1.167 2009/12/30 09:39:08 espie Exp $
+# $OpenBSD: PackingElement.pm,v 1.168 2010/01/01 13:36:07 espie Exp $
#
-# Copyright (c) 2003-2007 Marc Espie <espie@openbsd.org>
+# Copyright (c) 2003-2010 Marc Espie <espie@openbsd.org>
#
# Permission to use, copy, modify, and distribute this software for any
# purpose with or without fee is hereby granted, provided that the above
@@ -774,6 +774,8 @@ sub new
return OpenBSD::PackingElement::SystemPackage->new;
} elsif ($args eq 'always-update') {
return OpenBSD::PackingElement::AlwaysUpdate->new;
+ } elsif ($args eq 'explicit-update') {
+ return OpenBSD::PackingElement::ExplicitUpdate->new;
} else {
die "Unknown option: $args";
}
@@ -822,6 +824,13 @@ sub category()
'always-update';
}
+package OpenBSD::PackingElement::ExplicitUpdate;
+our @ISA=qw(OpenBSD::PackingElement::UniqueOption);
+
+sub category()
+{
+ 'explicit-update';
+}
# The special elements that don't end in the right place
package OpenBSD::PackingElement::ExtraInfo;
our @ISA=qw(OpenBSD::PackingElement::Unique OpenBSD::PackingElement::Comment);
diff --git a/usr.sbin/pkg_add/OpenBSD/PackingList.pm b/usr.sbin/pkg_add/OpenBSD/PackingList.pm
index 004e7657640..4e7a3fa1c97 100644
--- a/usr.sbin/pkg_add/OpenBSD/PackingList.pm
+++ b/usr.sbin/pkg_add/OpenBSD/PackingList.pm
@@ -1,7 +1,7 @@
# ex:ts=8 sw=4:
-# $OpenBSD: PackingList.pm,v 1.96 2009/12/30 09:39:08 espie Exp $
+# $OpenBSD: PackingList.pm,v 1.97 2010/01/01 13:36:07 espie Exp $
#
-# Copyright (c) 2003-2007 Marc Espie <espie@openbsd.org>
+# Copyright (c) 2003-2010 Marc Espie <espie@openbsd.org>
#
# Permission to use, copy, modify, and distribute this software for any
# purpose with or without fee is hereby granted, provided that the above
@@ -438,7 +438,7 @@ sub match_pkgpath
}
our @unique_categories =
- (qw(name url digital-signature no-default-conflict manual-installation always-update extrainfo localbase arch));
+ (qw(name url digital-signature no-default-conflict manual-installation always-update explicit-update extrainfo localbase arch));
our @list_categories =
(qw(conflict pkgpath incompatibility updateset depend