Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
[enhance] github: Added remaining updated files for github V3.
  • Loading branch information
nrs135 committed Sep 27, 2012
1 parent b368d8b commit 5aa653c
Show file tree
Hide file tree
Showing 15 changed files with 3,073 additions and 1,518 deletions.
9 changes: 7 additions & 2 deletions lib/stdlib/apis/github/auth/auth.opa
Expand Up @@ -21,7 +21,7 @@
* @destination public * @destination public
*/ */


//package stdlib.apis.github.auth package stdlib.apis.github.auth
import stdlib.apis.common import stdlib.apis.common
import stdlib.apis.github.lib import stdlib.apis.github.lib


Expand All @@ -34,6 +34,9 @@ type GHAuth.scope =
{user} /** DB read/write access to profile info only. */ {user} /** DB read/write access to profile info only. */
/ {public_repo} /** DB read/write access, and Git read access to public repos. */ / {public_repo} /** DB read/write access, and Git read access to public repos. */
/ {repo} /** DB read/write access, and Git read access to public and private repos */ / {repo} /** DB read/write access, and Git read access to public and private repos */
/ {repo_status} /** Read/write access to public and private repo statuses.
Does not include access to code - use repo for that. */
/ {delete_repo} /** Delete access to adminable repositories. */
/ {gist} /** Write access to gists. */ / {gist} /** Write access to gists. */


@private GHAp = {{ @private GHAp = {{
Expand All @@ -43,6 +46,8 @@ type GHAuth.scope =
| {user} -> "user" | {user} -> "user"
| {public_repo} -> "public_repo" | {public_repo} -> "public_repo"
| {repo} -> "repo" | {repo} -> "repo"
| {repo_status} -> "repo:status"
| {delete_repo} -> "delete_repo"
| {gist} -> "gist" | {gist} -> "gist"


}} }}
Expand Down Expand Up @@ -72,7 +77,7 @@ GHAuth(conf:GHAuth.conf) = {{
("code", code)] ("code", code)]
match GHLib.full_post(base, path, data, some) with match GHLib.full_post(base, path, data, some) with
| {some=c} -> | {some=c} ->
token = AL.get_field(AL.get_data(c), "access_token") token = AL.get_field(AL.get_data(c.content), "access_token")
if token == "" then {none} if token == "" then {none}
else {some=token} else {some=token}
| _ -> {none} | _ -> {none}
Expand Down
161 changes: 0 additions & 161 deletions lib/stdlib/apis/github/commit/commit.opa

This file was deleted.

0 comments on commit 5aa653c

Please sign in to comment.