Skip to content

Commit

Permalink
added macports
Browse files Browse the repository at this point in the history
  • Loading branch information
bit101 committed Nov 24, 2023
1 parent 802e675 commit 0e8f927
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions version
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ tools_elm=--version
tools_engrampa=--version
tools_eog=--version
tools_exa=-v
tools_eza=-v
tools_exfalso=-v
tools_expac=--version
tools_eyeD3=--version
Expand Down Expand Up @@ -137,6 +138,7 @@ tools_php=-v
tools_pip3=-V
tools_pip=-V
tools_pkg_config=--version
tools_port=version
tools_pyenv=-v
tools_python2=-V
tools_python3=-V
Expand Down Expand Up @@ -350,6 +352,23 @@ try_brew() {
fi
}

try_macports() {
# is macports installed?
command -v port >/dev/null 2>&1 || return

# pip is installed. let's try it
echo " checking macports..."

result=$(port list $1 2>/dev/null)
if [ "$result" != "" ]
then
echo $result
exit
fi
}



# User forgot to specify the program or a flag
if [ -z $1 ]
then
Expand Down Expand Up @@ -418,6 +437,7 @@ then
try_npm $1
try_pip $1
try_brew $1
try_macports $1

# should only get here if neither pacman or apt are installed
echo "version was unable to find any info on '$1'"
Expand Down

0 comments on commit 0e8f927

Please sign in to comment.