Another github v3 api implemented in viml
This is a viml library to access the Github API v3. With it, you can manage Github resources (repositories, user profiles, organizations, etc.) from viml scripts.
It is WIP, it will covers the full API.
If you have any question, any remark, or if you find a bug, or if there is something you can do with the API but not with Github-api.vim, please open an issue.
It is easy to install the lib via dein:
call dein#add('wsdjeg/GitHub.vim')
NOTE: For unauthenticated requests, the rate limit allows for up to 60 requests per hour. Unauthenticated requests are associated with the originating IP address, and not the user making requests.Increasing the unauthenticated rate limit, you need Create OAuth app, and set EVN: CLIENTID
and CLIENTSECRET
.
create issue:
function! CreateIssue(owner, repo) abort
let username = input('your github username:')
let password = input('your github password:')
let title = input('Issue title: ')
let issue = {
\ 'title': title,
\ 'body': s:body(),
\ }
let response = github#api#issues#Create(a:owner, a:repo,
\ username, password, issue)
if !empty(response)
echomsg 'Create successed! ' . response.url
else
echom 'Create failed!'
endif
endfunction
func! s:body()
return 'Testting Github.vim...'
endf
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。