From 0701e19f1e0f74ce1e4e93aae01d3225f5d35e63 Mon Sep 17 00:00:00 2001 From: c0dev0id Date: Mon, 23 Dec 2024 12:49:42 +0100 Subject: [PATCH] Update 2024-12-23 12:49 OpenBSD/amd64-t14 --- .bin/cam | 11 +-- .../pack/plugins/start/vim-cursorword/LICENSE | 21 ------ .../plugins/start/vim-cursorword/README.md | 12 ---- .../vim-cursorword/autoload/cursorword.vim | 58 --------------- .../start/vim-cursorword/doc/cursorword.txt | 72 ------------------- .../vim-cursorword/plugin/cursorword.vim | 32 --------- 6 files changed, 3 insertions(+), 203 deletions(-) delete mode 100644 .vim/pack/plugins/start/vim-cursorword/LICENSE delete mode 100644 .vim/pack/plugins/start/vim-cursorword/README.md delete mode 100644 .vim/pack/plugins/start/vim-cursorword/autoload/cursorword.vim delete mode 100644 .vim/pack/plugins/start/vim-cursorword/doc/cursorword.txt delete mode 100644 .vim/pack/plugins/start/vim-cursorword/plugin/cursorword.vim diff --git a/.bin/cam b/.bin/cam index 5c6fb40..ded563f 100755 --- a/.bin/cam +++ b/.bin/cam @@ -2,6 +2,7 @@ # defaults _format="-input_format mjpeg" +_dev="/dev/video0" # loop through arguments for arg in $@ @@ -29,14 +30,6 @@ then echo "unknown parameter(s): $_unknown" fi -# set device -if [ -z "$_dev" ] -then - _dev="/dev/video0" -else - _dev="/dev/video$_dev" -fi - # set resolution if [ x"$_res" == x"max" ] then @@ -97,5 +90,7 @@ then echo " 30 - set framerate to 30 fps" echo " 60 - set framerate to 60 fps" echo " - set video device number (defaults is 0)" + echo + echo " Note: ffplay may not start or fall back to internal defaults when options (or combinations thereof) are not supported by the camera." exit 2 fi diff --git a/.vim/pack/plugins/start/vim-cursorword/LICENSE b/.vim/pack/plugins/start/vim-cursorword/LICENSE deleted file mode 100644 index fdef580..0000000 --- a/.vim/pack/plugins/start/vim-cursorword/LICENSE +++ /dev/null @@ -1,21 +0,0 @@ -The MIT License (MIT) - -Copyright (c) 2015-2022 itchyny - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. diff --git a/.vim/pack/plugins/start/vim-cursorword/README.md b/.vim/pack/plugins/start/vim-cursorword/README.md deleted file mode 100644 index 8a6ab72..0000000 --- a/.vim/pack/plugins/start/vim-cursorword/README.md +++ /dev/null @@ -1,12 +0,0 @@ -# vim-cursorword -## Underlines the word under the cursor -![vim-cursorword](https://raw.githubusercontent.com/wiki/itchyny/vim-cursorword/image/image.gif) - -## Installation -Install with your favorite plugin manager. - -## Author -itchyny (https://github.com/itchyny) - -## License -This software is released under the MIT License, see LICENSE. diff --git a/.vim/pack/plugins/start/vim-cursorword/autoload/cursorword.vim b/.vim/pack/plugins/start/vim-cursorword/autoload/cursorword.vim deleted file mode 100644 index 2359b2c..0000000 --- a/.vim/pack/plugins/start/vim-cursorword/autoload/cursorword.vim +++ /dev/null @@ -1,58 +0,0 @@ -" ============================================================================= -" Filename: autoload/cursorword.vim -" Author: itchyny -" License: MIT License -" Last Change: 2022/11/17 08:57:47. -" ============================================================================= - -let s:save_cpo = &cpo -set cpo&vim - -function! cursorword#highlight() abort - if !get(g:, 'cursorword_highlight', 1) | return | endif - highlight default CursorWord term=underline cterm=underline gui=underline -endfunction - -let s:alphabets = '^[\x00-\x7f\xb5\xc0-\xd6\xd8-\xf6\xf8-\u01bf\u01c4-\u02af\u0370-\u0373\u0376\u0377\u0386-\u0481\u048a-\u052f]\+$' - -function! cursorword#matchadd(...) abort - let enable = get(b:, 'cursorword', get(g:, 'cursorword', 1)) && !has('vim_starting') - if !enable && !get(w:, 'cursorword_match') | return | endif - let i = (a:0 ? a:1 : mode() ==# 'i' || mode() ==# 'R') && col('.') > 1 - let line = getline('.') - let word = matchstr(line[:(col('.')-i-1)], '\k*$') . matchstr(line[(col('.')-i-1):], '^\k*')[1:] - if get(w:, 'cursorword_state', []) ==# [ word, enable ] | return | endif - let w:cursorword_state = [ word, enable ] - if get(w:, 'cursorword_match') - silent! call matchdelete(w:cursorword_id) - endif - let w:cursorword_match = 0 - if !enable || word ==# '' || len(word) !=# strchars(word) && word !~# s:alphabets || len(word) > 1000 | return | endif - let pattern = '\<' . escape(word, '~"\.^$[]*') . '\>' - let w:cursorword_id = matchadd('CursorWord', pattern, -100) - let w:cursorword_match = 1 -endfunction - -let s:delay = get(g:, 'cursorword_delay', 50) -if has('timers') && s:delay > 0 - let s:timer = 0 - function! cursorword#cursormoved() abort - if get(w:, 'cursorword_match') - silent! call matchdelete(w:cursorword_id) - let w:cursorword_match = 0 - let w:cursorword_state = [] - endif - call timer_stop(s:timer) - let s:timer = timer_start(s:delay, 'cursorword#timer_callback') - endfunction - function! cursorword#timer_callback(...) abort - call cursorword#matchadd() - endfunction -else - function! cursorword#cursormoved() abort - call cursorword#matchadd() - endfunction -endif - -let &cpo = s:save_cpo -unlet s:save_cpo diff --git a/.vim/pack/plugins/start/vim-cursorword/doc/cursorword.txt b/.vim/pack/plugins/start/vim-cursorword/doc/cursorword.txt deleted file mode 100644 index 52975d4..0000000 --- a/.vim/pack/plugins/start/vim-cursorword/doc/cursorword.txt +++ /dev/null @@ -1,72 +0,0 @@ -*cursorword.txt* Underlines the word under the cursor - -Author: itchyny (https://github.com/itchyny) -License: MIT License -Repository: https://github.com/itchyny/vim-cursorword -Last Change: 2022/11/17 18:55:06. - -CONTENTS *cursorword-contents* - -Introduction |cursorword-introduction| -Options |cursorword-options| -Changelog |cursorword-changelog| - -============================================================================== -INTRODUCTION *cursorword-introduction* -This *cursorword* plugin underlines the word under the cursor. That's it. - -While we are coding, we always pay attention to the variable under the cursor. -Where did we define the variable? In which statement do we use the variable? -Searching the variable using |star| or |#| is a simple solution to highlight all -the places the variable is used. However, it costs too much time to highlight -a word, move around to check the places and clear the highlight. This plugin -|cursorword| provides you the modest underlines for the variables under the -cursor to let you know all the places the variable is used at a glance without -stopping coding. - -The brightest plugin (https://github.com/osyo-manga/vim-brightest) is a nice -plugin to fulfill highlights of the word under the cursor. However, it uses -too long codes and is too slow. I had been using the plugin for a while but I -could not bear the slowness caused by brightest on the cursor motions. This is -why I created |cursorword|. I think that a plugin which is running all the time -should be coded with the performance efficiency in mind. When we publish a -plugin which stays running in all buffers, we should be aware that it will use -much resource of all the users. - -The code of |cursorword| is very tiny. It's very tiny that |cursorword| runs ten -times faster than brightest. Instead of its efficiency, |cursorword| is totally -unconfigurable. But you will find this plugin just comfortable; the modest -underlines are enough for us. A good configurable plugin would have many -options that users can configure almost all the features. But be relaxed and -imagine, do we need such a lot of options for a plugin to highlight the word -under the cursor? Most people would never need such a lot of options. We -should not implement features for a few power users at the sacrifice of the -performance of the software. Keep your software small for the happiness of -most users. Too much configurability makes your software dirty and causes -unwanted slowness on many users. We have to rethink what good configurability -is and for what kind of software such configurability is required. - -============================================================================== -OPTIONS *cursorword-options* - - g:cursorword *g:cursorword* - Set this variable to 0 to disable this plugin globally. - - b:cursorword *b:cursorword* - If you set this variable to 0, the plugin stops highlighting - the word under the cursor in the buffer. This variable has - priority over |g:cursorword|. - - g:cursorword_highlight *g:cursorword_highlight* - Set this variable to 0 to disable the default highlighting - style. If you set this variable to 0, you need to define your - own style for the CursorWord |highlight-groups|. - - g:cursorword_delay *g:cursorword_delay* - The delay duration in milliseconds for setting the word - highlight after cursor motions. When the value is set to 0, the - plugin highlights the word synchronously, but there is a - performance sacrifice. The default value is 50. - -============================================================================== -vim:tw=78:sw=4:ts=8:ft=help:norl:noet: diff --git a/.vim/pack/plugins/start/vim-cursorword/plugin/cursorword.vim b/.vim/pack/plugins/start/vim-cursorword/plugin/cursorword.vim deleted file mode 100644 index 5081bd9..0000000 --- a/.vim/pack/plugins/start/vim-cursorword/plugin/cursorword.vim +++ /dev/null @@ -1,32 +0,0 @@ -" ============================================================================= -" Filename: plugin/cursorword.vim -" Author: itchyny -" License: MIT License -" Last Change: 2020/05/01 19:05:29. -" ============================================================================= - -if exists('g:loaded_cursorword') || v:version < 703 - finish -endif -let g:loaded_cursorword = 1 - -let s:save_cpo = &cpo -set cpo&vim - -augroup cursorword - autocmd! - if has('vim_starting') - autocmd VimEnter * call cursorword#highlight() | - \ autocmd cursorword WinEnter,BufEnter * call cursorword#matchadd() - else - call cursorword#highlight() - autocmd WinEnter,BufEnter * call cursorword#matchadd() - endif - autocmd ColorScheme * call cursorword#highlight() - autocmd CursorMoved,CursorMovedI * call cursorword#cursormoved() - autocmd InsertEnter * call cursorword#matchadd(1) - autocmd InsertLeave * call cursorword#matchadd(0) -augroup END - -let &cpo = s:save_cpo -unlet s:save_cpo