Skip to content

Commit

Permalink
metacpan command that open the module's detail on metacpan.org
Browse files Browse the repository at this point in the history
  • Loading branch information
aereal committed Apr 9, 2013
1 parent fb90dba commit 632e5d3
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions bin/metacpan
@@ -0,0 +1,16 @@
#!/usr/bin/env zsh

open_command=''
open_args=''

if /usr/bin/which -s open; then
open_command='open'
open_args=''
fi

if [[ ! -x =$open_command ]]; then
echo "open-able command is not found." > /dev/stderr
exit 1
fi

$open_command $open_args "http://metacpan.org/module/$1"

0 comments on commit 632e5d3

Please sign in to comment.