fix(ftdetect): filetype is detected in vim and neovim

This commit is contained in:
Wuelner Martínez
2022-08-24 19:32:48 -06:00
parent ef5126c84a
commit 34732be5e9
3 changed files with 9 additions and 9 deletions

View File

@@ -4,6 +4,12 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
## [1.1.3] - 2022-08-24
### Fixed
- Filetype is detected in all versions of Vim and Neovim.
## [1.1.2] - 2022-08-22 ## [1.1.2] - 2022-08-22
### Fixed ### Fixed

View File

@@ -58,7 +58,7 @@ NOTE: Vim does not provide Stylus support by default, but you can install [vim-s
## Credits ## Credits
- Based on: [Evan Lecklider's](https://github.com/evanleck) [vim-svelte](https://github.com/evanleck/vim-svelte). - Based on: Plugin [vim-svelte](https://github.com/evanleck/vim-svelte) by. [Evan Lecklider's](https://github.com/evanleck).
## License ## License

View File

@@ -3,14 +3,8 @@
" Author: Wuelner Martínez <wuelner.martinez@outlook.com> " Author: Wuelner Martínez <wuelner.martinez@outlook.com>
" Maintainer: Wuelner Martínez <wuelner.martinez@outlook.com> " Maintainer: Wuelner Martínez <wuelner.martinez@outlook.com>
" URL: https://github.com/wuelnerdotexe/vim-astro " URL: https://github.com/wuelnerdotexe/vim-astro
" Last Change: 2022 Aug 22 " Last Change: 2022 Aug 24
" Whether to set the Astro filetype on *.astro files. " Whether to set the Astro filetype on *.astro files.
function! s:DetectFiletypeAstro() autocmd BufNewFile,BufRead *.astro setfiletype astro
if (&filetype ==# '') || (&filetype !=# 'astro')
setfiletype astro
endif
endfunction
autocmd BufNewFile,BufRead *.astro call <SID>DetectFiletypeAstro()
" vim: ts=8 " vim: ts=8