{"action":"created","issue":{"url":"https://api.github.com/repos/junegunn/vim-plug/issues/480","repository_url":"https://api.github.com/repos/junegunn/vim-plug","labels_url":"https://api.github.com/repos/junegunn/vim-plug/issues/480/labels{/name}","comments_url":"https://api.github.com/repos/junegunn/vim-plug/issues/480/comments","events_url":"https://api.github.com/repos/junegunn/vim-plug/issues/480/events","html_url":"https://github.com/junegunn/vim-plug/issues/480","id":151556394,"number":480,"title":"vim-plug fails to PlugUpdate if no master branch exists","user":{"login":"crowell","id":616288,"avatar_url":"https://avatars.githubusercontent.com/u/616288?v=3","gravatar_id":"","url":"https://api.github.com/users/crowell","html_url":"https://github.com/crowell","followers_url":"https://api.github.com/users/crowell/followers","following_url":"https://api.github.com/users/crowell/following{/other_user}","gists_url":"https://api.github.com/users/crowell/gists{/gist_id}","starred_url":"https://api.github.com/users/crowell/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/crowell/subscriptions","organizations_url":"https://api.github.com/users/crowell/orgs","repos_url":"https://api.github.com/users/crowell/repos","events_url":"https://api.github.com/users/crowell/events{/privacy}","received_events_url":"https://api.github.com/users/crowell/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2016-04-28T06:04:33Z","updated_at":"2016-04-30T04:29:56Z","closed_at":null,"body":"<!--\r\n### Before Submitting\r\n\r\n- You checked the [faq](https://github.com/junegunn/vim-plug/wiki/faq) for common problems.\r\n- Check your [requirements](https://github.com/junegunn/vim-plug/wiki/requirements) are satisfied.\r\n- You are not going to suggest vim-plug manage itself like Vundle, see #240, #364, #367 ...\r\n-->\r\n\r\nManaging `Plug 'rdnetto/YCM-Generator'` with `:PlugUpdate` fails with this error\r\n\r\n`x YCM-Generator: error: pathspec 'master' did not match any file(s) known to git. `\r\n\r\nYCM-Generator only has https://github.com/rdnetto/YCM-Generator stable and develop branches, not master. Vim-Plug assumes that i want master, which isn't the case. Whatever the current in-use branch is, is the one I want.\r\n\r\n------------------------------\r\nI'm using the latest from master now\r\n<!-- Put the contents of `:version` below -->\r\n```\r\n41de3c713c0b82700bfcb50a45e9d7756a2cce96\r\n```\r\n\r\n<!-- Check all that apply. -->\r\n- Type:\r\n    - [x] Bug\r\n    - [ ] Enhancement\r\n    - [ ] Feature Request\r\n    - [ ] Question\r\n- OS:\r\n    - [x] All/Other\r\n    - [ ] Linux\r\n    - [ ] OS X\r\n    - [ ] Windows\r\n- Vim:\r\n    - [x] Terminal Vim\r\n    - [x] GVim\r\n    - [x] Neovim\r\n"},"comment":{"url":"https://api.github.com/repos/junegunn/vim-plug/issues/comments/215934530","html_url":"https://github.com/junegunn/vim-plug/issues/480#issuecomment-215934530","issue_url":"https://api.github.com/repos/junegunn/vim-plug/issues/480","id":215934530,"user":{"login":"junegunn","id":700826,"avatar_url":"https://avatars.githubusercontent.com/u/700826?v=3","gravatar_id":"","url":"https://api.github.com/users/junegunn","html_url":"https://github.com/junegunn","followers_url":"https://api.github.com/users/junegunn/followers","following_url":"https://api.github.com/users/junegunn/following{/other_user}","gists_url":"https://api.github.com/users/junegunn/gists{/gist_id}","starred_url":"https://api.github.com/users/junegunn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/junegunn/subscriptions","organizations_url":"https://api.github.com/users/junegunn/orgs","repos_url":"https://api.github.com/users/junegunn/repos","events_url":"https://api.github.com/users/junegunn/events{/privacy}","received_events_url":"https://api.github.com/users/junegunn/received_events","type":"User","site_admin":false},"created_at":"2016-04-30T04:29:56Z","updated_at":"2016-04-30T04:29:56Z","body":"The idea was to prevent the case where the user manually checks out a non-default, experimental branch, forgets about it, and vim-plug stops updating the plugin. By explicitly specifying the name of the branch with `master` as the default allows vim-plug to easily verify the status of the clone. The obvious downside of this approach is that it doesn't work well with plugins that do not use `master` as their default branches. But since there are very few such plugins, I didn't bother to find a proper solution to it. I wonder if there's a way to find the default branch without contacting the remote again and without external bookkeeping."}}