From f6d53abba83b298c069578d867612e3d5e062c67 Mon Sep 17 00:00:00 2001 From: David Jones Date: Wed, 26 Aug 2015 15:54:49 +1000 Subject: [PATCH 1/4] Complete GitHubCommitCommitAuthor.php Fill in some missing code. --- client/objects/GitHubCommitCommitAuthor.php | 40 ++++++++++++++++++++- 1 file changed, 39 insertions(+), 1 deletion(-) diff --git a/client/objects/GitHubCommitCommitAuthor.php b/client/objects/GitHubCommitCommitAuthor.php index 678ea28..e2c27d2 100644 --- a/client/objects/GitHubCommitCommitAuthor.php +++ b/client/objects/GitHubCommitCommitAuthor.php @@ -17,6 +17,44 @@ protected function getAttributes() 'email' => 'string', )); } - + + /** + * @var string + */ + protected $name; + + /** + * @var string + */ + protected $date; + + /** + * @var string + */ + protected $email; + + /** + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * @return string + */ + public function getDate() + { + return $this->date; + } + + /** + * @return string + */ + public function getEmail() + { + return $this->email; + } } From d4ff97a7839d9e98d7ec2c28b52b7c552af20697 Mon Sep 17 00:00:00 2001 From: jdarwood007 Date: Fri, 13 Nov 2015 19:17:28 -0800 Subject: [PATCH 2/4] Added parameters to listIssues API --- client/services/GitHubIssues.php | 30 +++++++++++++++++++++++++++++- 1 file changed, 29 insertions(+), 1 deletion(-) diff --git a/client/services/GitHubIssues.php b/client/services/GitHubIssues.php index cb6c0b7..87652ad 100644 --- a/client/services/GitHubIssues.php +++ b/client/services/GitHubIssues.php @@ -99,11 +99,39 @@ public function listAllIssues($owner = false, $filter = null, $state = null, $la /** * List issues * + * @param $milestone number (Optional) - Milestone to associate this issue with. + * @param state string Indicates the state of the issues to return. Can be either open, closed, or all. Default: open + * @param $assignee string (Optional) - Login for the user that this issue should be assigned to. + * @param $creator string (Optional) - Login for the user that created this issue. + * @param $mentioned string (Optional) - Login for a user mentioned in this issue. + * @param labels string A list of comma separated label names. Example: bug,ui,@high + * @param sort string What to sort results by. Can be either created, updated, comments. Default: created + * @param direction string The direction of the sort. Can be either asc or desc. Default: desc + * @param since string Only issues updated at or after this time are returned. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ. + * * @return array */ - public function listIssues($owner, $repo) + public function listIssues($owner, $repo, $milestone = null, $state = null, $assignee = null, $creator = null, $mentioned = null, $labels = null, $sort = null, $direction = null, $since) { $data = array(); + if(!is_null($milestone)) + $data['milestone'] = $milestone; + if(!is_null($state)) + $data['state'] = $state; + if(!is_null($assignee)) + $data['assignee'] = $assignee; + if(!is_null($creator)) + $data['creator'] = $creator; + if(!is_null($mentioned)) + $data['mentioned'] = $mentioned; + if(!is_null($labels)) + $data['labels'] = $labels; + if(!is_null($sort)) + $data['sort'] = $sort; + if(!is_null($direction)) + $data['direction'] = $direction; + if(!is_null($since)) + $data['since'] = $since; return $this->client->request("/repos/$owner/$repo/issues", 'GET', $data, 200, 'GitHubIssue', true); } From 2b6e8233ca7176f8c6bd57f25a026a0dd50debbc Mon Sep 17 00:00:00 2001 From: jdarwood007 Date: Fri, 13 Nov 2015 19:24:40 -0800 Subject: [PATCH 3/4] Missed a Null --- client/services/GitHubIssues.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/client/services/GitHubIssues.php b/client/services/GitHubIssues.php index 87652ad..e555d4a 100644 --- a/client/services/GitHubIssues.php +++ b/client/services/GitHubIssues.php @@ -111,7 +111,7 @@ public function listAllIssues($owner = false, $filter = null, $state = null, $la * * @return array */ - public function listIssues($owner, $repo, $milestone = null, $state = null, $assignee = null, $creator = null, $mentioned = null, $labels = null, $sort = null, $direction = null, $since) + public function listIssues($owner, $repo, $milestone = null, $state = null, $assignee = null, $creator = null, $mentioned = null, $labels = null, $sort = null, $direction = null, $since = null) { $data = array(); if(!is_null($milestone)) From 8a283d73049aaa6c92f8aabbff5baa8cba63731c Mon Sep 17 00:00:00 2001 From: tan-tan-kanarek Date: Thu, 26 Nov 2015 09:32:33 +0200 Subject: [PATCH 4/4] MIT license --- license.txt | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 license.txt diff --git a/license.txt b/license.txt new file mode 100644 index 0000000..6a3bad9 --- /dev/null +++ b/license.txt @@ -0,0 +1,26 @@ +Copyright (c) + + + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + + + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + + + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. +