From 844374fb0f6f1e3b7f3a322e02fdbcde184502ae Mon Sep 17 00:00:00 2001 From: Christian Neukirchen Date: Tue, 10 Feb 2015 11:18:08 +0100 Subject: add xnodev --- README | 1 + xnodev | 11 +++++++++++ 2 files changed, 12 insertions(+) create mode 100755 xnodev diff --git a/README b/README index ae4ca4f..40d1848 100644 --- a/README +++ b/README @@ -19,6 +19,7 @@ https://github.com/voidlinux/xbps xls PKGS... - list files contained in PKGS (including binpkgs) xmindep PKGS... - minimize list of PKGS by removing implicit dependencies xnew PKG - create XBPS template template + xnodev - list not installed -devel packages for installed packages xoptdiff [-q] [PKGS...] - show template options which differ from binary package xq [-R] PKGS... - query information about XBPS package xsrc PKG - list source files for XBPS template diff --git a/xnodev b/xnodev new file mode 100755 index 0000000..d146a15 --- /dev/null +++ b/xnodev @@ -0,0 +1,11 @@ +#!/bin/bash +# xnodev - list not installed -devel packages for installed packages + +xbps-query -Rs '' | sed 's/^.\(.\). \([^ ]*\)-.* .*/\1 \2/' | sort -k2 | awk ' + $1 == "-" && $2 ~ "-devel" { + b = $2 + sub("-devel", "", b) + if (s[b]) print $2 + } + $1 == "*" { s[$2] = 1 } +' -- cgit 1.4.1