diff options
author | Frederick Yin <fkfd@macaw.me> | 2020-06-20 18:43:16 +0800 |
---|---|---|
committer | Frederick Yin <fkfd@macaw.me> | 2020-06-20 18:43:16 +0800 |
commit | c6d86838dcd22296278b249d995b0b38632a82bf (patch) | |
tree | df7bcc6bea7f421d0846acf3187042f772bc0137 /git-gmi/gateway.py | |
parent | 036159de2770b5ca9698474dd15fb63e04a51190 (diff) |
Refs view
Diffstat (limited to 'git-gmi/gateway.py')
-rw-r--r-- | git-gmi/gateway.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/git-gmi/gateway.py b/git-gmi/gateway.py index bb7f2e0..671d5cd 100644 --- a/git-gmi/gateway.py +++ b/git-gmi/gateway.py @@ -73,5 +73,13 @@ def handle_cgi_request(path: str, query: str): print(STATUS_TEMPORARY_FAILURE) return + elif view == "refs": + try: + print(repo.view_refs()) + return + except: + print(STATUS_TEMPORARY_FAILURE) + return + handle_cgi_request(environ.get("PATH_INFO"), environ.get("QUERY_STRING")) |