repo.dcgi - gophercgis - Collection of gopher CGI/DCGI for geomyidae
 (HTM) hg clone https://bitbucket.org/iamleot/gophercgis
 (DIR) Log
 (DIR) Files
 (DIR) Refs
 (DIR) README
 (DIR) LICENSE
       ---
       repo.dcgi
       ---
            1 #!/bin/sh
            2 
            3 . ../common/config.sh
            4 
            5 ISSUE_CGI="${CGI_BASEDIR}/github/issue.dcgi"
            6 ISSUES_CGI="${CGI_BASEDIR}/github/issues.dcgi"
            7 COMMITS_CGI="${CGI_BASEDIR}/github/commits.dcgi"
            8 PULLS_CGI="${CGI_BASEDIR}/github/pulls.dcgi"
            9 
           10 
           11 case "$2" in
           12 */*)
           13         owner=${2%%/*}
           14         repo=${2##*/}
           15         ;;
           16 *)
           17         exit 1
           18         ;;
           19 esac
           20 
           21 
           22 url="https://api.github.com/repos/${owner}/${repo}"
           23 curl -Lgs -- "${url}" |
           24     jq -r '
           25     "t",
           26     "tGitHub - \(.full_name)",
           27     "t",
           28     "[h|Homepage|URL:\(.homepage)|server|port]",
           29     "t",
           30     "t\(.name) - \(.description)",
           31     "t",
           32     "tStargazers:  \(.stargazers_count)",
           33     "tSubscribers: \(.subscribers_count)",
           34     "t",
           35     "[1|Issues|'"${ISSUES_CGI}?${owner}/${repo}"'|server|port]",
           36     "[1|Pull requests|'"${PULLS_CGI}?${owner}/${repo}"'|server|port]",
           37     "[1|Commits|'"${COMMITS_CGI}?${owner}/${repo}"'|server|port]",
           38     "t",
           39     "[h|Clone (HTTP)|URL:\(.clone_url)|server|port]",
           40     "[h|Clone (Git)|URL:\(.git_url)|server|port]",
           41     "[h|Clone (SSH)|URL:\(.ssh_url)|server|port]"
           42 '