Created
October 31, 2023 15:17
-
-
Save jmroot/e6fb957b7051e0ecbdd3565d6a269b79 to your computer and use it in GitHub Desktop.
Check if a port has an archive available
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #! /usr/bin/env port-tclsh | |
| package require macports | |
| mportinit | |
| array set portinfo [lindex [mportlookup [lindex $argv 0]] 1] | |
| set mport [mportopen $portinfo(porturl) [list subport $portinfo(name)] ""] | |
| set available [[ditem_key $mport workername] eval [list _archive_available]] | |
| if {$available} { | |
| set status has | |
| } else { | |
| set status "does not have" | |
| } | |
| puts "$portinfo(name) $status an archive available" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment