{"action":"created","comment":{"url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/pulls/comments/24305406","id":24305406,"diff_hunk":"@@ -66,10 +67,10 @@ fu! s:record(bufnr)\n endf\n \n fu! s:addtomrufs(fname)\n-\tlet fn = fnamemodify(a:fname, ':p')\n+\tlet fn = fnamemodify(a:fname, g:ctrlp_mruf_tilde_homedir ? ':p:~' : ':p')\n \tlet fn = exists('+ssl') ? tr(fn, '/', '\\') : fn\n \tif ( !empty({s:in}) && fn !~# {s:in} ) || ( !empty({s:ex}) && fn =~# {s:ex} )\n-\t\t\\ || !empty(getbufvar('^'.fn.'$', '&bt')) || !filereadable(fn) | retu\n+\t\t\\ || !empty(getbufvar('^'.fnamemodify(fn,':p').'$', '&bt')) || !filereadable(fnamemodify(fn,':p')) | retu","path":"autoload/ctrlp/mrufiles.vim","position":17,"original_position":17,"commit_id":"553f25050c52f730ba5cd3326b01a7a96b93dd50","original_commit_id":"553f25050c52f730ba5cd3326b01a7a96b93dd50","user":{"login":"ludovicchabant","id":470376,"avatar_url":"https://avatars.githubusercontent.com/u/470376?v=3","gravatar_id":"","url":"https://api.github.com/users/ludovicchabant","html_url":"https://github.com/ludovicchabant","followers_url":"https://api.github.com/users/ludovicchabant/followers","following_url":"https://api.github.com/users/ludovicchabant/following{/other_user}","gists_url":"https://api.github.com/users/ludovicchabant/gists{/gist_id}","starred_url":"https://api.github.com/users/ludovicchabant/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ludovicchabant/subscriptions","organizations_url":"https://api.github.com/users/ludovicchabant/orgs","repos_url":"https://api.github.com/users/ludovicchabant/repos","events_url":"https://api.github.com/users/ludovicchabant/events{/privacy}","received_events_url":"https://api.github.com/users/ludovicchabant/received_events","type":"User","site_admin":false},"body":"I think you could keep the previous code from line 69, but store it in a different variable (like `abs_fn` instead of `fn`) so you don't need to call `fnamemodify` twice here.","created_at":"2015-02-09T01:24:53Z","updated_at":"2015-02-09T01:24:53Z","html_url":"https://github.com/ctrlpvim/ctrlp.vim/pull/76#discussion_r24305406","pull_request_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/pulls/76","_links":{"self":{"href":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/pulls/comments/24305406"},"html":{"href":"https://github.com/ctrlpvim/ctrlp.vim/pull/76#discussion_r24305406"},"pull_request":{"href":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/pulls/76"}}},"pull_request":{"url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/pulls/76","id":28864717,"html_url":"https://github.com/ctrlpvim/ctrlp.vim/pull/76","diff_url":"https://github.com/ctrlpvim/ctrlp.vim/pull/76.diff","patch_url":"https://github.com/ctrlpvim/ctrlp.vim/pull/76.patch","issue_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/issues/76","number":76,"state":"open","locked":false,"title":"Remove typo to uniformize dir path & Make $HOME in MRU relative","user":{"login":"Konfekt","id":7195553,"avatar_url":"https://avatars.githubusercontent.com/u/7195553?v=3","gravatar_id":"","url":"https://api.github.com/users/Konfekt","html_url":"https://github.com/Konfekt","followers_url":"https://api.github.com/users/Konfekt/followers","following_url":"https://api.github.com/users/Konfekt/following{/other_user}","gists_url":"https://api.github.com/users/Konfekt/gists{/gist_id}","starred_url":"https://api.github.com/users/Konfekt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Konfekt/subscriptions","organizations_url":"https://api.github.com/users/Konfekt/orgs","repos_url":"https://api.github.com/users/Konfekt/repos","events_url":"https://api.github.com/users/Konfekt/events{/privacy}","received_events_url":"https://api.github.com/users/Konfekt/received_events","type":"User","site_admin":false},"body":"Commit https://github.com/Konfekt/ctrlp.vim/commit/f6cb0f07eb41ea47eb83efc2e75a123abbad6d10 resolves that  `:CtrlPBookmarkDir!` adds the `cwd` twice: With and without a trailing slash.\r\n\r\nCommit https://github.com/Konfekt/ctrlp.vim/commit/553f25050c52f730ba5cd3326b01a7a96b93dd50 adds an option `g:ctrlp_mruf_tilde_homedir` to save MRU and `CtrlPBookmarkDir!` added paths (that can be used to build a directory MRU) as path's relative to the home dir. That is, with `g:ctrlp_mruf_tilde_homedir=1` (but = 0 by default) `/home/username/file` will be saved as `~/file`.\r\n\r\nThis way,\r\n\r\n* the MRU contains less unnecessary clutter, and\r\n* the MRU stays valid if the full path of $HOME changes (for example on Windows, under cygwin and under other accounts)","created_at":"2015-02-07T14:18:43Z","updated_at":"2015-02-09T01:24:53Z","closed_at":null,"merged_at":null,"merge_commit_sha":"ced85f74e2408245f8b14d37f6fc58dde07e07b7","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/pulls/76/commits","review_comments_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/pulls/76/comments","review_comment_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/pulls/comments/{number}","comments_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/issues/76/comments","statuses_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/statuses/553f25050c52f730ba5cd3326b01a7a96b93dd50","head":{"label":"Konfekt:master","ref":"master","sha":"553f25050c52f730ba5cd3326b01a7a96b93dd50","user":{"login":"Konfekt","id":7195553,"avatar_url":"https://avatars.githubusercontent.com/u/7195553?v=3","gravatar_id":"","url":"https://api.github.com/users/Konfekt","html_url":"https://github.com/Konfekt","followers_url":"https://api.github.com/users/Konfekt/followers","following_url":"https://api.github.com/users/Konfekt/following{/other_user}","gists_url":"https://api.github.com/users/Konfekt/gists{/gist_id}","starred_url":"https://api.github.com/users/Konfekt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Konfekt/subscriptions","organizations_url":"https://api.github.com/users/Konfekt/orgs","repos_url":"https://api.github.com/users/Konfekt/repos","events_url":"https://api.github.com/users/Konfekt/events{/privacy}","received_events_url":"https://api.github.com/users/Konfekt/received_events","type":"User","site_admin":false},"repo":{"id":30457795,"name":"ctrlp.vim","full_name":"Konfekt/ctrlp.vim","owner":{"login":"Konfekt","id":7195553,"avatar_url":"https://avatars.githubusercontent.com/u/7195553?v=3","gravatar_id":"","url":"https://api.github.com/users/Konfekt","html_url":"https://github.com/Konfekt","followers_url":"https://api.github.com/users/Konfekt/followers","following_url":"https://api.github.com/users/Konfekt/following{/other_user}","gists_url":"https://api.github.com/users/Konfekt/gists{/gist_id}","starred_url":"https://api.github.com/users/Konfekt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Konfekt/subscriptions","organizations_url":"https://api.github.com/users/Konfekt/orgs","repos_url":"https://api.github.com/users/Konfekt/repos","events_url":"https://api.github.com/users/Konfekt/events{/privacy}","received_events_url":"https://api.github.com/users/Konfekt/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Konfekt/ctrlp.vim","description":"Active fork of kien/ctrlp.vim—Fuzzy file, buffer, mru, tag, etc finder.","fork":true,"url":"https://api.github.com/repos/Konfekt/ctrlp.vim","forks_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/forks","keys_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/teams","hooks_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/hooks","issue_events_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/issues/events{/number}","events_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/events","assignees_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/assignees{/user}","branches_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/branches{/branch}","tags_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/tags","blobs_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/git/refs{/sha}","trees_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/statuses/{sha}","languages_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/languages","stargazers_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/stargazers","contributors_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/contributors","subscribers_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/subscribers","subscription_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/subscription","commits_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/commits{/sha}","git_commits_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/git/commits{/sha}","comments_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/comments{/number}","issue_comment_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/issues/comments/{number}","contents_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/contents/{+path}","compare_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/merges","archive_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/downloads","issues_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/issues{/number}","pulls_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/pulls{/number}","milestones_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/milestones{/number}","notifications_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/labels{/name}","releases_url":"https://api.github.com/repos/Konfekt/ctrlp.vim/releases{/id}","created_at":"2015-02-07T14:16:09Z","updated_at":"2015-02-07T16:03:47Z","pushed_at":"2015-02-07T16:03:47Z","git_url":"git://github.com/Konfekt/ctrlp.vim.git","ssh_url":"git@github.com:Konfekt/ctrlp.vim.git","clone_url":"https://github.com/Konfekt/ctrlp.vim.git","svn_url":"https://github.com/Konfekt/ctrlp.vim","homepage":"ctrlpvim.github.com/ctrlp.vim","size":1258,"stargazers_count":0,"watchers_count":0,"language":"VimL","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":true,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"ctrlpvim:master","ref":"master","sha":"bc94048c41acaeaf3e4e9d4a6b3074a9f5cb9775","user":{"login":"ctrlpvim","id":8335435,"avatar_url":"https://avatars.githubusercontent.com/u/8335435?v=3","gravatar_id":"","url":"https://api.github.com/users/ctrlpvim","html_url":"https://github.com/ctrlpvim","followers_url":"https://api.github.com/users/ctrlpvim/followers","following_url":"https://api.github.com/users/ctrlpvim/following{/other_user}","gists_url":"https://api.github.com/users/ctrlpvim/gists{/gist_id}","starred_url":"https://api.github.com/users/ctrlpvim/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ctrlpvim/subscriptions","organizations_url":"https://api.github.com/users/ctrlpvim/orgs","repos_url":"https://api.github.com/users/ctrlpvim/repos","events_url":"https://api.github.com/users/ctrlpvim/events{/privacy}","received_events_url":"https://api.github.com/users/ctrlpvim/received_events","type":"Organization","site_admin":false},"repo":{"id":22539592,"name":"ctrlp.vim","full_name":"ctrlpvim/ctrlp.vim","owner":{"login":"ctrlpvim","id":8335435,"avatar_url":"https://avatars.githubusercontent.com/u/8335435?v=3","gravatar_id":"","url":"https://api.github.com/users/ctrlpvim","html_url":"https://github.com/ctrlpvim","followers_url":"https://api.github.com/users/ctrlpvim/followers","following_url":"https://api.github.com/users/ctrlpvim/following{/other_user}","gists_url":"https://api.github.com/users/ctrlpvim/gists{/gist_id}","starred_url":"https://api.github.com/users/ctrlpvim/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ctrlpvim/subscriptions","organizations_url":"https://api.github.com/users/ctrlpvim/orgs","repos_url":"https://api.github.com/users/ctrlpvim/repos","events_url":"https://api.github.com/users/ctrlpvim/events{/privacy}","received_events_url":"https://api.github.com/users/ctrlpvim/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ctrlpvim/ctrlp.vim","description":"Active fork of kien/ctrlp.vim—Fuzzy file, buffer, mru, tag, etc finder.","fork":true,"url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim","forks_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/forks","keys_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/teams","hooks_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/hooks","issue_events_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/issues/events{/number}","events_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/events","assignees_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/assignees{/user}","branches_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/branches{/branch}","tags_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/tags","blobs_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/git/refs{/sha}","trees_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/statuses/{sha}","languages_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/languages","stargazers_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/stargazers","contributors_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/contributors","subscribers_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/subscribers","subscription_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/subscription","commits_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/commits{/sha}","git_commits_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/git/commits{/sha}","comments_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/comments{/number}","issue_comment_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/issues/comments/{number}","contents_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/contents/{+path}","compare_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/merges","archive_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/downloads","issues_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/issues{/number}","pulls_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/pulls{/number}","milestones_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/milestones{/number}","notifications_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/labels{/name}","releases_url":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/releases{/id}","created_at":"2014-08-02T04:56:13Z","updated_at":"2015-02-08T12:18:32Z","pushed_at":"2015-02-02T05:26:02Z","git_url":"git://github.com/ctrlpvim/ctrlp.vim.git","ssh_url":"git@github.com:ctrlpvim/ctrlp.vim.git","clone_url":"https://github.com/ctrlpvim/ctrlp.vim.git","svn_url":"https://github.com/ctrlpvim/ctrlp.vim","homepage":"ctrlpvim.github.com/ctrlp.vim","size":1959,"stargazers_count":203,"watchers_count":203,"language":"VimL","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":true,"forks_count":10,"mirror_url":null,"open_issues_count":26,"forks":10,"open_issues":26,"watchers":203,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/pulls/76"},"html":{"href":"https://github.com/ctrlpvim/ctrlp.vim/pull/76"},"issue":{"href":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/issues/76"},"comments":{"href":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/issues/76/comments"},"review_comments":{"href":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/pulls/76/comments"},"review_comment":{"href":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/pulls/76/commits"},"statuses":{"href":"https://api.github.com/repos/ctrlpvim/ctrlp.vim/statuses/553f25050c52f730ba5cd3326b01a7a96b93dd50"}}}}