diff --git a/packages/vim-python/build.sh b/packages/vim-python/build.sh index 33e00ec19..ddde4fd1c 100644 --- a/packages/vim-python/build.sh +++ b/packages/vim-python/build.sh @@ -6,6 +6,7 @@ TERMUX_PKG_RECOMMENDS="diffutils" # vim should only be updated every 50 releases on multiples of 50. # Update both vim and vim-python to the same version in one PR. TERMUX_PKG_VERSION=8.1.1150 +TERMUX_PKG_REVISION=1 TERMUX_PKG_SHA256=3f5a614ffe829a5d1ce47ae1ccaa471af105c33a5e1b2316aabd4dd9894ec7c7 TERMUX_PKG_SRCURL="https://github.com/vim/vim/archive/v${TERMUX_PKG_VERSION}.tar.gz" TERMUX_PKG_EXTRA_CONFIGURE_ARGS=" diff --git a/packages/vim-python/vimrc b/packages/vim-python/vimrc index 45d68a236..9ffc57c51 100644 --- a/packages/vim-python/vimrc +++ b/packages/vim-python/vimrc @@ -1,3 +1,6 @@ +" Ensure that <> notation works for the mappings that follow +set nocompatible + " Scroll only one line for mouse wheel events to get smooth scrolling on touch screens map imap @@ -10,13 +13,22 @@ set mouse=a " sensible.vim - Defaults everyone can agree on " Maintainer: Tim Pope -" Version: 1.1 +" Version: 1.2 -set nocompatible -let g:loaded_sensible = 1 +if exists('g:loaded_sensible') || &compatible + finish +else + let g:loaded_sensible = 'yes' +endif -filetype plugin indent on -syntax enable +if has('autocmd') + filetype plugin indent on +endif +if has('syntax') && !exists('g:syntax_on') + syntax enable +endif + +" Use :help 'option' to see the documentation for the given option. set autoindent set backspace=indent,eol,start @@ -25,8 +37,10 @@ set smarttab set nrformats-=octal -set ttimeout -set ttimeoutlen=100 +if !has('nvim') && &ttimeoutlen == -1 + set ttimeout + set ttimeoutlen=100 +endif set incsearch " Use to clear the highlighting of :set hlsearch. @@ -46,7 +60,9 @@ if !&sidescrolloff endif set display+=lastline -set encoding=utf-8 +if &encoding ==# 'latin1' && has('gui_running') + set encoding=utf-8 +endif if &listchars ==# 'eol:$' set listchars=tab:>\ ,trail:-,extends:>,precedes:<,nbsp:+ @@ -60,6 +76,10 @@ if has('path_extra') setglobal tags-=./tags tags-=./tags; tags^=./tags; endif +if &shell =~# 'fish$' && (v:version < 704 || v:version == 704 && !has('patch276')) + set shell=/data/data/com.termux/files/usr/bin/env\ bash +endif + set autoread if &history < 1000 @@ -84,3 +104,5 @@ if !exists('g:loaded_matchit') && findfile('plugin/matchit.vim', &rtp) ==# '' endif inoremap u + +" vim:set ft=vim et sw=2: diff --git a/packages/vim/build.sh b/packages/vim/build.sh index 5c04d28b9..4ae0094b4 100644 --- a/packages/vim/build.sh +++ b/packages/vim/build.sh @@ -6,6 +6,7 @@ TERMUX_PKG_RECOMMENDS="diffutils" # vim should only be updated every 50 releases on multiples of 50. # Update both vim and vim-python to the same version in one PR. TERMUX_PKG_VERSION=8.1.1150 +TERMUX_PKG_REVISION=1 TERMUX_PKG_SHA256=3f5a614ffe829a5d1ce47ae1ccaa471af105c33a5e1b2316aabd4dd9894ec7c7 TERMUX_PKG_SRCURL="https://github.com/vim/vim/archive/v${TERMUX_PKG_VERSION}.tar.gz" TERMUX_PKG_EXTRA_CONFIGURE_ARGS=" diff --git a/packages/vim/vimrc b/packages/vim/vimrc index 45d68a236..9ffc57c51 100644 --- a/packages/vim/vimrc +++ b/packages/vim/vimrc @@ -1,3 +1,6 @@ +" Ensure that <> notation works for the mappings that follow +set nocompatible + " Scroll only one line for mouse wheel events to get smooth scrolling on touch screens map imap @@ -10,13 +13,22 @@ set mouse=a " sensible.vim - Defaults everyone can agree on " Maintainer: Tim Pope -" Version: 1.1 +" Version: 1.2 -set nocompatible -let g:loaded_sensible = 1 +if exists('g:loaded_sensible') || &compatible + finish +else + let g:loaded_sensible = 'yes' +endif -filetype plugin indent on -syntax enable +if has('autocmd') + filetype plugin indent on +endif +if has('syntax') && !exists('g:syntax_on') + syntax enable +endif + +" Use :help 'option' to see the documentation for the given option. set autoindent set backspace=indent,eol,start @@ -25,8 +37,10 @@ set smarttab set nrformats-=octal -set ttimeout -set ttimeoutlen=100 +if !has('nvim') && &ttimeoutlen == -1 + set ttimeout + set ttimeoutlen=100 +endif set incsearch " Use to clear the highlighting of :set hlsearch. @@ -46,7 +60,9 @@ if !&sidescrolloff endif set display+=lastline -set encoding=utf-8 +if &encoding ==# 'latin1' && has('gui_running') + set encoding=utf-8 +endif if &listchars ==# 'eol:$' set listchars=tab:>\ ,trail:-,extends:>,precedes:<,nbsp:+ @@ -60,6 +76,10 @@ if has('path_extra') setglobal tags-=./tags tags-=./tags; tags^=./tags; endif +if &shell =~# 'fish$' && (v:version < 704 || v:version == 704 && !has('patch276')) + set shell=/data/data/com.termux/files/usr/bin/env\ bash +endif + set autoread if &history < 1000 @@ -84,3 +104,5 @@ if !exists('g:loaded_matchit') && findfile('plugin/matchit.vim', &rtp) ==# '' endif inoremap u + +" vim:set ft=vim et sw=2: