{"id":8,"date":"2009-09-20T20:58:11","date_gmt":"2009-09-21T01:58:11","guid":{"rendered":"http:\/\/ebixio.com\/wordpress\/?p=8"},"modified":"2009-09-20T20:58:11","modified_gmt":"2009-09-21T01:58:11","slug":"vim-syntax-for-xaml-files","status":"publish","type":"post","link":"http:\/\/ebixio.com\/blog\/2009\/09\/20\/vim-syntax-for-xaml-files\/","title":{"rendered":"Vim syntax for xaml files"},"content":{"rendered":"<p>So you&#8217;re using Windows and want to edit your xaml files every once in a while with vi\/vim\/gvim, but vim doesn&#8217;t recognize xaml as an xml file and doesn&#8217;t give you nice syntax highlighting? Simple fix. In your home directory, create a <code inline=\"on\">vimfiles\/ftdetect\/myrules.vim<\/code> file with the following contents:<\/p>\n\n<code lang=\"vim\">\n\" We set the type to XML only if no type was detected yet\nau BufRead,BufNewFile *.xaml\t\t\tsetfiletype xml\n\" OR unconditionally\n\"au BufRead,BufNewFile *.xaml set filetype=xml\n<\/code>","protected":false},"excerpt":{"rendered":"<p>So you&#8217;re using Windows and want to edit your xaml files every once in a while with vi\/vim\/gvim, but vim doesn&#8217;t recognize xaml as an xml file and doesn&#8217;t give you nice syntax highlighting? Simple fix. In your home directory, create a vimfiles\/ftdetect\/myrules.vim file with the following contents: &#8221; We set the type to XML [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"footnotes":""},"categories":[1],"tags":[10,9,8],"class_list":["post-8","post","type-post","status-publish","format-standard","hentry","category-uncategorized","tag-csharp","tag-vim","tag-windows"],"_links":{"self":[{"href":"http:\/\/ebixio.com\/blog\/wp-json\/wp\/v2\/posts\/8","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/ebixio.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/ebixio.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/ebixio.com\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"http:\/\/ebixio.com\/blog\/wp-json\/wp\/v2\/comments?post=8"}],"version-history":[{"count":0,"href":"http:\/\/ebixio.com\/blog\/wp-json\/wp\/v2\/posts\/8\/revisions"}],"wp:attachment":[{"href":"http:\/\/ebixio.com\/blog\/wp-json\/wp\/v2\/media?parent=8"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/ebixio.com\/blog\/wp-json\/wp\/v2\/categories?post=8"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/ebixio.com\/blog\/wp-json\/wp\/v2\/tags?post=8"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}