From 8790a90cee7318be2929b6d8c57580332df30121 Mon Sep 17 00:00:00 2001 From: Michael Shigorin Date: Fri, 2 Dec 2011 17:47:53 +0200 Subject: [PATCH] pkgdups.sh and semi-random tagged pkglists shuffle The bin/pkgdups.sh script comes from m-p-d in considerably optimized form and is to be used with the pkglist files of interest passed as its arguments to produce a "hall of duplicates" among those. The tagged lists received some updates along the rescue image lines, most of those are actually inspired by http://rescuecd.pld-linux.org/ and to lesser extent a few articles on rescue/recovery/forensics software -- so some newcomers are even employed already. --- bin/pkgdups.sh | 20 +++++++++++++ conf.d/live.mk | 3 +- pkg.in/lists/tagged/README | 2 +- pkg.in/lists/tagged/archive+base | 6 ++++ pkg.in/lists/tagged/archive+extra | 30 +++++++++++++++++++ pkg.in/lists/tagged/base+comm | 5 ++++ pkg.in/lists/tagged/base+compression | 6 ---- ...esystem,alterator => basesystem+alterator} | 0 .../tagged/{desktop,icewm => desktop+icewm} | 0 pkg.in/lists/tagged/dev+security | 3 ++ pkg.in/lists/tagged/network+bench | 3 ++ .../tagged/{extra+network => network+extra} | 0 pkg.in/lists/tagged/network+security | 4 +++ .../tagged/{extra+rescue => rescue+extra} | 10 +------ pkg.in/lists/tagged/rescue+fs | 8 +++++ pkg.in/lists/tagged/security+extra | 9 ++++++ pkg.in/lists/tagged/server+openvpn | 11 +++++++ pkg.in/lists/tagged/server,openvpn | 11 ------- 18 files changed, 103 insertions(+), 28 deletions(-) create mode 100755 bin/pkgdups.sh create mode 100644 pkg.in/lists/tagged/archive+base create mode 100644 pkg.in/lists/tagged/archive+extra create mode 100644 pkg.in/lists/tagged/base+comm delete mode 100644 pkg.in/lists/tagged/base+compression rename pkg.in/lists/tagged/{basesystem,alterator => basesystem+alterator} (100%) rename pkg.in/lists/tagged/{desktop,icewm => desktop+icewm} (100%) create mode 100644 pkg.in/lists/tagged/dev+security create mode 100644 pkg.in/lists/tagged/network+bench rename pkg.in/lists/tagged/{extra+network => network+extra} (100%) create mode 100644 pkg.in/lists/tagged/network+security rename pkg.in/lists/tagged/{extra+rescue => rescue+extra} (92%) create mode 100644 pkg.in/lists/tagged/rescue+fs create mode 100644 pkg.in/lists/tagged/security+extra create mode 100644 pkg.in/lists/tagged/server+openvpn delete mode 100644 pkg.in/lists/tagged/server,openvpn diff --git a/bin/pkgdups.sh b/bin/pkgdups.sh new file mode 100755 index 00000000..452a7144 --- /dev/null +++ b/bin/pkgdups.sh @@ -0,0 +1,20 @@ +#!/bin/sh +# a script to help weed out duplicate packages +# contained in package lists given as arguments +# +# Requires: libshell + +. /bin/shell-quote + +sort "$@" \ +| grep -v '^ *#' \ +| sed -s 's,[ ]\+, ,g' \ +| grep -v '^ *$' \ +| uniq -cd \ +| while read num str; do + echo -n "$str: $num "; + pattern="`quote_sed_regexp "$str"`" + grep -l "^$pattern$" "$@" | tr '\n' ' ' + echo +done \ +| sort -rn -t: -k2 diff --git a/conf.d/live.mk b/conf.d/live.mk index ecf38d6b..6d89999c 100644 --- a/conf.d/live.mk +++ b/conf.d/live.mk @@ -9,8 +9,9 @@ distro/live-install: distro/.base use/live/install use/syslinux/localboot.cfg distro/live-icewm: distro/live use/live/icewm distro/live-rescue: distro/live-icewm - @$(call add,LIVE_LISTS,$(call tags,extra && (rescue || network))) @$(call add,LIVE_LISTS,$(call tags,rescue && (live || x11))) + @$(call add,LIVE_LISTS, \ + $(call tags,(base || extra) && (archive || rescue || network))) distro/live-isomd5sum: distro/.base use/live/base use/isomd5sum @$(call add,LIVE_PACKAGES,livecd-isomd5sum) diff --git a/pkg.in/lists/tagged/README b/pkg.in/lists/tagged/README index 04bce784..3c2f72e4 100644 --- a/pkg.in/lists/tagged/README +++ b/pkg.in/lists/tagged/README @@ -2,7 +2,7 @@ реализация (tags2lists) требует, чтобы каждый из тегов был отдельным словом, состоящим из символов из набора a-zA-Z0-9_ (внимание: не используйте в слове "-"); рекомендуется -разделять слова "+" или "," (стандарт ещё не устоялся). +разделять слова "+". Предположительное применение: дополнение функциональности, заданной статически (наследственно или явно), факультативным diff --git a/pkg.in/lists/tagged/archive+base b/pkg.in/lists/tagged/archive+base new file mode 100644 index 00000000..89d6c327 --- /dev/null +++ b/pkg.in/lists/tagged/archive+base @@ -0,0 +1,6 @@ +bzip2 +cpio +gzip +tar +xz +zip diff --git a/pkg.in/lists/tagged/archive+extra b/pkg.in/lists/tagged/archive+extra new file mode 100644 index 00000000..0cd8f589 --- /dev/null +++ b/pkg.in/lists/tagged/archive+extra @@ -0,0 +1,30 @@ +#gzrt +lzip +lzop +p7zip +pax +rzip +star +unrar +unzip +xar + +# parallel (de)compression +lbzip2 +pbzip2 +pigz +plzip +pxz + +# legacy +arj +cabextract +ha +lha +mscompress +nomarch +ncompress +unace +unarj +unzoo +uudeview diff --git a/pkg.in/lists/tagged/base+comm b/pkg.in/lists/tagged/base+comm new file mode 100644 index 00000000..eb713956 --- /dev/null +++ b/pkg.in/lists/tagged/base+comm @@ -0,0 +1,5 @@ +ckermit +lrzsz +minicom +picocom +sredird diff --git a/pkg.in/lists/tagged/base+compression b/pkg.in/lists/tagged/base+compression deleted file mode 100644 index 6464ddb6..00000000 --- a/pkg.in/lists/tagged/base+compression +++ /dev/null @@ -1,6 +0,0 @@ -# compression -cpio -p7zip -tar -unzip -zip diff --git a/pkg.in/lists/tagged/basesystem,alterator b/pkg.in/lists/tagged/basesystem+alterator similarity index 100% rename from pkg.in/lists/tagged/basesystem,alterator rename to pkg.in/lists/tagged/basesystem+alterator diff --git a/pkg.in/lists/tagged/desktop,icewm b/pkg.in/lists/tagged/desktop+icewm similarity index 100% rename from pkg.in/lists/tagged/desktop,icewm rename to pkg.in/lists/tagged/desktop+icewm diff --git a/pkg.in/lists/tagged/dev+security b/pkg.in/lists/tagged/dev+security new file mode 100644 index 00000000..67e8855a --- /dev/null +++ b/pkg.in/lists/tagged/dev+security @@ -0,0 +1,3 @@ +flawfinder +rats +valgrind diff --git a/pkg.in/lists/tagged/network+bench b/pkg.in/lists/tagged/network+bench new file mode 100644 index 00000000..82b4e53c --- /dev/null +++ b/pkg.in/lists/tagged/network+bench @@ -0,0 +1,3 @@ +httperf +nepim + diff --git a/pkg.in/lists/tagged/extra+network b/pkg.in/lists/tagged/network+extra similarity index 100% rename from pkg.in/lists/tagged/extra+network rename to pkg.in/lists/tagged/network+extra diff --git a/pkg.in/lists/tagged/network+security b/pkg.in/lists/tagged/network+security new file mode 100644 index 00000000..81c97dbe --- /dev/null +++ b/pkg.in/lists/tagged/network+security @@ -0,0 +1,4 @@ +aircrack-ng +#kismet* +macchanger +tcptrace diff --git a/pkg.in/lists/tagged/extra+rescue b/pkg.in/lists/tagged/rescue+extra similarity index 92% rename from pkg.in/lists/tagged/extra+rescue rename to pkg.in/lists/tagged/rescue+extra index 42f2ea81..0516a35d 100644 --- a/pkg.in/lists/tagged/extra+rescue +++ b/pkg.in/lists/tagged/rescue+extra @@ -27,6 +27,7 @@ partimage # Applications binutils dmidecode +gnupg hexedit pciutils procps @@ -36,14 +37,6 @@ sharutils time openssl -# Applications/Archiving -arj -bzip2 -gzip -unrar -unzip -zip - # Applications/Editors vim-console @@ -51,7 +44,6 @@ vim-console findutils file less -mtools # Filesystem utils dosfstools diff --git a/pkg.in/lists/tagged/rescue+fs b/pkg.in/lists/tagged/rescue+fs new file mode 100644 index 00000000..be9a9fa2 --- /dev/null +++ b/pkg.in/lists/tagged/rescue+fs @@ -0,0 +1,8 @@ +cpipe +dar +ddrescue +foremost +ntfsprogs +sleuthkit +xfsdump +#zfs-fuse diff --git a/pkg.in/lists/tagged/security+extra b/pkg.in/lists/tagged/security+extra new file mode 100644 index 00000000..02bff1c4 --- /dev/null +++ b/pkg.in/lists/tagged/security+extra @@ -0,0 +1,9 @@ +apg +#chkrootkit +dcfldd +john +#logcheck +md5deep +osec +osec-cronjob +osec-mailreport diff --git a/pkg.in/lists/tagged/server+openvpn b/pkg.in/lists/tagged/server+openvpn new file mode 100644 index 00000000..df1aec71 --- /dev/null +++ b/pkg.in/lists/tagged/server+openvpn @@ -0,0 +1,11 @@ +apt +basesystem +sysklogd +etcnet +glibc-nss +openvpn +netlist +#alterator-fbi +openssh-server +passwd +less diff --git a/pkg.in/lists/tagged/server,openvpn b/pkg.in/lists/tagged/server,openvpn deleted file mode 100644 index 842f3f04..00000000 --- a/pkg.in/lists/tagged/server,openvpn +++ /dev/null @@ -1,11 +0,0 @@ -apt -basesystem -sysklogd -etcnet -glibc-nss -openvpn -netlist -#alterator-fbi -openssh-server -passwd -less