[151026] contrib/mp-buildbot/mpbb-list-subports

ryandesign at macports.org ryandesign at macports.org
Fri Aug 5 10:25:43 PDT 2016


Revision: 151026
          https://trac.macports.org/changeset/151026
Author:   ryandesign at macports.org
Date:     2016-08-05 10:25:43 -0700 (Fri, 05 Aug 2016)
Log Message:
-----------
mp-buildbot: add mpbb-list-subports

Added Paths:
-----------
    contrib/mp-buildbot/mpbb-list-subports

Added: contrib/mp-buildbot/mpbb-list-subports
===================================================================
--- contrib/mp-buildbot/mpbb-list-subports	                        (rev 0)
+++ contrib/mp-buildbot/mpbb-list-subports	2016-08-05 17:25:43 UTC (rev 151026)
@@ -0,0 +1,21 @@
+#!/bin/bash
+
+# Note:
+# This script is sourced by the its wrapper script.
+# Do not execute this directly!
+
+
+list-subports-help() {
+    echo "Print the name of port --port and any subports."
+}
+
+list-subports() {
+    if [ -z "${option_port}" ]; then
+        errmsg "--port is required"
+        return 1
+    fi
+
+    for subport in "${option_port}" $(port echo subportof:"${option_port}" 2>/dev/null); do
+        echo $subport
+    done
+}
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/macports-changes/attachments/20160805/f5848c06/attachment.html>


More information about the macports-changes mailing list