mmozuras / vim-github-comment Goto Github PK
View Code? Open in Web Editor NEWComment commits on GitHub using Vim
License: MIT License
Comment commits on GitHub using Vim
License: MIT License
Install went fine, set my username and it generated a token with correct permissions.
I go into a file, add a comment, and it opens the browser with the link. But no comment appears!
Yes, "show notes" is ticked (and can be ticked), but nothing appears :/
Maybe you could crib the way it's done in https://github.com/mattn/gist-vim? This is a really cool looking plugin, but 2FA users can't use it at the moment.
The plugin is failing to comment due to a failure in the GetDiffLineNumber
function.
Error detected while processing function GHComment..<SNR>93_GetDiffLineNumber:
line 5:
E684: list index out of range: 0
E15: Invalid expression: split_line[0] - 6
Could not create comment. You may not have the rights.
I am using git 2.2.2 and vim 7.4.488.
https://github.com/mattn/gist-vim looks for the github user name in one's .gitconfig
in the custom [github]
section.
[github]
user = justinmk
The code for this isn't too bad:
if !exists('g:github_user')
let g:github_user = substitute(s:system('git config --get github.user'), "\n", '', '')
endif
Perhaps vim-github-comment can look for this as an alternative to g:github_user
, since vim-github-comment is in the "family" of plugins that use @mattn's webapi. It would be nice to see some convergence of configuration conventions in the various Vim "github plugins".
Tried on windows, installed via vim-plug:
Plug 'mattn/webapi-vim'
Plug 'mmozuras/vim-github-comment'
Seems to download and install fine, but on trying to execute the GHComment command, asks for password, I enter the password, and it gives:
Not Found
github-comment auth failed
Any suggestions? Thanks!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.