You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
"GitHub's [Statuses API][statuses] is one of the more popular recent additions to GitHub's large and all-encompassing API. This API allows you to create and list statuses like those created by popular Continuous Integration services (e.g., Jenkins, Travis CI, etc.). github3.py provides unfettered access to these functions and the following should help explore that functionality.\n",
"With a repository object, we can now retrieve the statuses from a number of different commit-like objects which we can retrieve using the repository's ``commit`` method."
"Each of these bindings now hold a reference to a different ``RepoCommit`` object and each has a ``statuses`` method. We can retrieve statuses about each reference and print them."
76
+
]
77
+
},
78
+
{
79
+
"cell_type": "code",
80
+
"collapsed": false,
81
+
"input": [
82
+
"for ref in (commit, tag, branch):\n",
83
+
" print('Showing statuses for \"{0.sha}\" ({0.html_url})'.format(ref))\n",
"Showing statuses for \"9df71a9772d5f43e332c855a32d4689f28289989\" (https://github.com/sigmavirus24/github3.py/commit/9df71a9772d5f43e332c855a32d4689f28289989)\n",
95
+
" State: success; Description: The Travis CI build passed; Context: continuous-integration/travis-ci"
96
+
]
97
+
},
98
+
{
99
+
"output_type": "stream",
100
+
"stream": "stdout",
101
+
"text": [
102
+
"\n",
103
+
" State: pending; Description: The Travis CI build is in progress; Context: continuous-integration/travis-ci\n",
104
+
" State: pending; Description: The Travis CI build is in progress; Context: continuous-integration/travis-ci\n",
105
+
"Showing statuses for \"52a3f30e05cf434285e775979f01f1a8355049a7\" (https://github.com/sigmavirus24/github3.py/commit/52a3f30e05cf434285e775979f01f1a8355049a7)\n",
106
+
" State: success; Description: The Travis CI build passed; Context: continuous-integration/travis-ci"
107
+
]
108
+
},
109
+
{
110
+
"output_type": "stream",
111
+
"stream": "stdout",
112
+
"text": [
113
+
"\n",
114
+
" State: success; Description: The Travis CI build passed; Context: continuous-integration/travis-ci\n",
115
+
" State: pending; Description: The Travis CI build is in progress; Context: continuous-integration/travis-ci\n",
116
+
" State: pending; Description: The Travis CI build is in progress; Context: continuous-integration/travis-ci\n",
117
+
" State: pending; Description: The Travis CI build is in progress; Context: continuous-integration/travis-ci\n",
118
+
" State: pending; Description: The Travis CI build is in progress; Context: continuous-integration/travis-ci\n",
119
+
"Showing statuses for \"6e97462ade3d8855644296e7a44b5463c7b222a6\" (https://github.com/sigmavirus24/github3.py/commit/6e97462ade3d8855644296e7a44b5463c7b222a6)\n",
120
+
" State: success; Description: The Travis CI build passed; Context: continuous-integration/travis-ci"
121
+
]
122
+
},
123
+
{
124
+
"output_type": "stream",
125
+
"stream": "stdout",
126
+
"text": [
127
+
"\n",
128
+
" State: pending; Description: The Travis CI build is in progress; Context: continuous-integration/travis-ci\n",
129
+
" State: pending; Description: The Travis CI build is in progress; Context: continuous-integration/travis-ci\n"
0 commit comments