{"id":128,"date":"2013-02-25T14:16:16","date_gmt":"2013-02-25T05:16:16","guid":{"rendered":"http:\/\/tech.eshima.info\/?p=128"},"modified":"2013-02-25T14:16:16","modified_gmt":"2013-02-25T05:16:16","slug":"vim%e3%81%a7%e3%82%b9%e3%83%8b%e3%83%9a%e3%83%83%e3%83%88%e3%81%8c%e4%bd%bf%e3%81%88%e3%82%8b%e3%82%88%e3%81%86%e3%81%ab%e8%a8%ad%e5%ae%9a","status":"publish","type":"post","link":"https:\/\/tech.eshima.info\/?p=128","title":{"rendered":"vim\u3067\u30b9\u30cb\u30da\u30c3\u30c8\u304c\u4f7f\u3048\u308b\u3088\u3046\u306b\u8a2d\u5b9a"},"content":{"rendered":"<p>\u3088\u304f\u4f7f\u3046\u30c6\u30ad\u30b9\u30c8\u30d1\u30bf\u30fc\u30f3\u3092\u4e00\u767a\u3067\u51fa\u305b\u308b\u3088\u3046\u306b\u3057\u305f\u3044\u3068\u8003\u3048\u3066<br \/>\nIME\u306e\u8f9e\u66f8\u767b\u9332\u306a\u3069\u3092\u8abf\u3079\u305f\u3051\u3069\u6539\u884c\u306b\u5bfe\u5fdc\u3057\u3066\u304a\u3089\u305a\u3001<br \/>\n\u6539\u884c\u3082\u542b\u3081\u3066\u9ad8\u5ea6\u306a\u8a2d\u5b9a\u304c\u3067\u304d\u308b\u3088\u3046\u306b\u601d\u3044\u5207\u3063\u3066\u4f5c\u696d\u3002<\/p>\n<h4>\u6e96\u5099<\/h4>\n<p>vim\u306eplugin\u3092\u7ba1\u7406\u3059\u308b\u30c4\u30fc\u30eb\u3092\u5165\u308c\u308b<\/p>\n<pre>\r\n% git clone https:\/\/github.com\/gmarik\/vundle.git ~\/.vim\/bundle\/vundle\r\n<\/pre>\n<p>\u30b9\u30cb\u30da\u30c3\u30c8\u3092\u4f7f\u3048\u308b\u3088\u3046\u306b\u3059\u308b\u30d7\u30e9\u30b0\u30a4\u30f3\u3092\u5165\u308c\u308b<\/p>\n<pre>\r\n% git clone git:\/\/github.com\/Shougo\/neobundle.vim ~\/.vim\/bundle\/neobundle.vim\r\n<\/pre>\n<p>\u3064\u3044\u3067\u306b\u3001\u5404\u8a00\u8a9e\u306e\u30b9\u30cb\u30da\u30c3\u30c8\u96c6\u3092\u5165\u308c\u308b<\/p>\n<pre>\r\n% git clone https:\/\/github.com\/honza\/snipmate-snippets.git ~\/.vim\/bundle\/snipmate-snippets\r\n<\/pre>\n<p>.vimrc\u306b\u4e0b\u8a18\u3092\u8ffd\u8a18<br \/>\n\u6700\u5f8c\u306e\u884c\u306b\u3042\u308b\u306e\u304c\u30b9\u30cb\u30da\u30c3\u30c8\u3092\u8a2d\u5b9a\u3057\u3066\u3044\u308b\u30d5\u30a1\u30a4\u30eb\u3092\u898b\u306b\u884c\u304f\u90e8\u5206\u3002<br \/>\n~\/.vim\/mysnippets<br \/>\n\u304c\u81ea\u5206\u7528\u306e\u30d5\u30a1\u30a4\u30eb\u3092\u7f6e\u304f\u6240\u306b\u3057\u305f\u3002<\/p>\n<pre>\r\n\r\n\"--------------------------------------------------------------------------\r\n\" neobundle\r\nset nocompatible               \" Be iMproved\r\nfiletype off                   \" Required!\r\n\r\nif has('vim_starting')\r\n  set runtimepath+=~\/.vim\/bundle\/neobundle.vim\/\r\n  endif\r\n\r\n  call neobundle#rc(expand('~\/.vim\/bundle\/'))\r\n\r\n  filetype plugin indent on     \" Required!\r\n\r\n  \" Installation check.\r\n  if neobundle#exists_not_installed_bundles()\r\n\t  echomsg 'Not installed bundles : ' .\r\n\t          \\ string(neobundle#get_not_installed_bundle_names())\r\n\t  echomsg 'Please execute \":NeoBundleInstall\" command.'\r\n\t    \"finish\r\nendif\r\nNeoBundle 'Shougo\/neocomplcache.git'\r\nNeoBundle 'Shougo\/neosnippet.git'\r\n\r\n\" Plugin key-mappings.\r\nimap <C-k>     <Plug>(neosnippet_expand_or_jump)\r\nsmap <C-k>     <Plug>(neosnippet_expand_or_jump)\r\n\r\n\" SuperTab like snippets behavior.\r\nimap <expr><TAB> neosnippet#expandable_or_jumpable() ? \"\\<Plug>(neosnippet_expand_or_jump)\" : pumvisible() ? \"\\<C-n>\" : \"\\<TAB>\"\r\nsmap <expr><TAB> neosnippet#expandable_or_jumpable() ?\"\\<Plug>(neosnippet_expand_or_jump)\" : \"\\<TAB>\"\r\n\r\n\" For snippet_complete marker.\r\nif has('conceal')\r\n  set conceallevel=2 concealcursor=i\r\nendif\r\n\" Tell Neosnippet about the other snippets\r\nlet g:neosnippet#snippets_directory='~\/.vim\/bundle\/snipmate-snippets\/snippets, ~\/.vim\/mysnippets'\r\n<\/pre>\n<p>vim\u3092\u8d77\u52d5\u3055\u305b\u3066\u3001\u4e0b\u8a18\u306e\u30b3\u30de\u30f3\u30c9\u3092\u6253\u3064\u3053\u3068\u3067\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3055\u308c\u308b<\/p>\n<pre>\r\n:BundleInstall\r\n<\/pre>\n<h4>\u81ea\u5206\u7528\u306e\u8a2d\u5b9a\u30d5\u30a1\u30a4\u30eb<\/h4>\n<p>.vimrc\u3067\u8a2d\u5b9a\u3057\u305f\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u3001<br \/>\n\u3053\u3053\u3067\u306f<br \/>\n~\/.vim\/mysnippets<br \/>\n\u306e\u4e2d\u306b\u8a2d\u5b9a\u30d5\u30a1\u30a4\u30eb\u3092\u4f5c\u308b\u3002<\/p>\n<p>\u3053\u3053\u3067\u3001<\/p>\n<pre>\r\n\u62e1\u5f35\u5b50\u540d.snippets\r\n<\/pre>\n<p>\u3068\u3044\u3046\u30d5\u30a1\u30a4\u30eb\u3092\u8a2d\u5b9a\u3059\u308b\u3068\u3001\u305d\u306e\u62e1\u5f35\u5b50\u306e\u30d5\u30a1\u30a4\u30eb\u3092vim\u3067\u958b\u3044\u305f\u6642\u306b<br \/>\n\u8a2d\u5b9a\u3057\u305f\u30b9\u30cb\u30da\u30c3\u30c8\u304c\u9069\u7528\u3055\u308c\u308b\u4ed5\u7d44\u307f\u3002<\/p>\n<p>\u4f8b\u3048\u3070\u3001<\/p>\n<pre>\r\nphp.snippets\r\n<\/pre>\n<p>\u3068\u3044\u3046\u30d5\u30a1\u30a4\u30eb\u3092\u4f5c\u308b\u3068php\u30d5\u30a1\u30a4\u30eb\u306b\u9069\u7528\u3055\u308c\u308b\u3002<\/p>\n<p>\u3057\u304b\u3057\u3001\u4eca\u56de\u5b9f\u65bd\u3057\u305f\u304b\u3063\u305f\u306e\u306ftxt\u30d5\u30a1\u30a4\u30eb\u3067<\/p>\n<pre>\r\ntxt.snippets\r\n<\/pre>\n<p>\u3068\u3044\u3046\u30d5\u30a1\u30a4\u30eb\u3092\u4f5c\u3063\u3066\u3082\u3069\u3046\u3057\u3066\u3082\u52d5\u4f5c\u3057\u306a\u304b\u3063\u305f\u3002<br \/>\n\uff08\u8ab0\u304b\u3084\u308a\u65b9\u308f\u304b\u308b\u65b9\u3044\u308c\u3070\u6559\u3048\u3066\u304f\u3060\u3055\u3044\uff09<\/p>\n<p>\u3057\u304b\u305f\u304c\u306a\u3044\u306e\u3067<\/p>\n<pre>\r\n_.snip\r\n<\/pre>\n<p>\u3068\u3044\u3046\u30d5\u30a1\u30a4\u30eb\u3092\u4f5c\u6210\u3002\u3053\u308c\u306f\u62e1\u5f35\u5b50\u306b\u95a2\u308f\u3089\u305a\u3001<br \/>\n\u5168\u3066\u306e\u30d5\u30a1\u30a4\u30eb\u306b\u9069\u7528\u3055\u308c\u308b\u3002<\/p>\n<h4>\u30b9\u30cb\u30da\u30c3\u30c8\u306e\u8a2d\u5b9a<\/h4>\n<p>\u3042\u3068\u306f\u81ea\u5206\u306e\u4fbf\u5229\u306a\u3088\u3046\u306b\u8a2d\u5b9a\u3059\u308b\u3002<\/p>\n<pre>\r\nsnippet ahaha\r\n 1gyoume\r\n 2gyoume\r\n 3gyoume\r\n<\/pre>\n<p>\u3068\u8a2d\u5b9a\u3057\u3066\u304a\u3051\u3070\u3001vim\u3067ahaha\u3068\u5165\u529b\u3057\u305f\u5f8c\u3067Ctrl+k\u3068\u6253\u3064\u3068<br \/>\n1gyoume<br \/>\n2gyoume<br \/>\n3gyoume<br \/>\n\u3068\u51fa\u529b\u3055\u308c\u308b\u3002<\/p>\n<p>\u4ed6\u306b\u3082\u3001\u304b\u306a\u308a\u9ad8\u5ea6\u306a\u3053\u3068\u3082\u53ef\u80fd\u3002<\/p>\n<pre>\r\nsnippet hogef\r\n  function hogef {\r\n        ${1:code}\r\n  }\r\n<\/pre>\n<p>\u306a\u3069\u3068\u3059\u308b\u3068\u3001\u5165\u529b\u3055\u308c\u305f\u4e0a\u306b\u6307\u5b9a\u5834\u6240\u306b\u30ab\u30fc\u30bd\u30eb\u304c\u5408\u3063\u305f\u72b6\u614b\u3067<br \/>\n\u30a4\u30f3\u30b5\u30fc\u30c8\u30e2\u30fc\u30c9\u306b\u306a\u3063\u3066\u3044\u308b\u305f\u3081<br \/>\n\u3059\u3050\u306b\u4e2d\u8eab\u3092\u5165\u529b\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u308b\u3002<\/p>\n<h4>\u5fdc\u7528<\/h4>\n<p>.vimrc\u306e\u4e2d\u8eab\u3092\u5909\u66f4\u3059\u308b\u3053\u3068\u3067\u30b9\u30cb\u30da\u30c3\u30c8\u306e\u9069\u7528\u65b9\u6cd5\u3082\u5909\u3048\u308c\u308b\u307f\u305f\u3044\u3002<br \/>\n\u8272\u3005\u3068\u4f7f\u3063\u3066\u307f\u306a\u304c\u3089\u3001\u81ea\u5206\u306e\u4f7f\u3044\u3084\u3059\u3044\u3088\u3046\u306b\u8a2d\u5b9a\u3092\u5909\u66f4\u3057\u3066\u3044\u304f\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u3088\u304f\u4f7f\u3046\u30c6\u30ad\u30b9\u30c8\u30d1\u30bf\u30fc\u30f3\u3092\u4e00\u767a\u3067\u51fa\u305b\u308b\u3088\u3046\u306b\u3057\u305f\u3044 [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[5],"tags":[],"class_list":["post-128","post","type-post","status-publish","format-standard","hentry","category-5"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/tech.eshima.info\/index.php?rest_route=\/wp\/v2\/posts\/128","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/tech.eshima.info\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/tech.eshima.info\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/tech.eshima.info\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/tech.eshima.info\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=128"}],"version-history":[{"count":2,"href":"https:\/\/tech.eshima.info\/index.php?rest_route=\/wp\/v2\/posts\/128\/revisions"}],"predecessor-version":[{"id":130,"href":"https:\/\/tech.eshima.info\/index.php?rest_route=\/wp\/v2\/posts\/128\/revisions\/130"}],"wp:attachment":[{"href":"https:\/\/tech.eshima.info\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=128"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/tech.eshima.info\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=128"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/tech.eshima.info\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=128"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}