Mercurial > vim
changeset 20:7cc13548becc
updating coc, prompts and auto loggin
| author | Luka Sitas <lsitas@avatarasoftware.com> |
|---|---|
| date | Thu, 26 Feb 2026 12:30:11 -0500 |
| parents | 1c8e1cdb35f7 |
| children | 20ce06ac3a68 |
| files | .vimrc coc-settings.json plugins/vim-ai/roles.ini plugins/voicenote/README.md |
| diffstat | 4 files changed, 107 insertions(+), 8 deletions(-) [+] |
line wrap: on
line diff
--- a/.vimrc Tue Jan 06 14:00:08 2026 -0500 +++ b/.vimrc Thu Feb 26 12:30:11 2026 -0500 @@ -33,6 +33,7 @@ autocmd Filetype scss if getfsize(@%) > 300 | setlocal syntax=OFF | endif highlight Comment cterm=italic gui=italic autocmd FileType *.blade.php setlocal commentstring=#\ %s +autocmd BufNewFile,BufRead *.php set iskeyword+=$ set path+=** set nowrap " Dont wrap @@ -97,21 +98,17 @@ " Coding and language specifics " " LSP - ale -source $HOME/.vim/plugins/ale.vim +" source $HOME/.vim/plugins/ale.vim " Blade Plug 'jwalton512/vim-blade', { 'for': 'php' } " Use release branch (recommended) source $HOME/.vim/plugins/coc.vim +Plug 'phpactor/phpactor', {'for': 'php', 'tag': '*', 'do': 'composer install --no-dev -o'}" Plug 'preservim/tagbar' " AI-ify Plug 'madox2/vim-ai' -" LLama.vim -" put before llama.vim loads -" let g:llama_config = { 'show_info': 0, 'endpoint': 'http://127.0.0.1:8012/infill' } -" Plug 'ggml-org/llama.vim' - call plug#end() " CTRLP @@ -127,3 +124,25 @@ " Get some better php support for ale see https://github.com/dense-analysis/ale/blob/master/supported-tools.md + + + +" Log current working directory with timestamp to a cache file +function! LogCwdToCache() + " Path to your cache file (change if you want) + let l:cachefile = expand('~/.vim_cwd_cache') + + " Get timestamp and current working directory + let l:timestamp = strftime('%Y-%m-%d %H:%M:%S') + let l:cwd = getcwd() + + " Append line: "YYYY-MM-DD HH:MM:SS /path/to/dir" + call writefile([l:timestamp . ' ' . l:cwd], l:cachefile, 'a') +endfunction + +" Example mappings/commands to trigger it: +" Call manually: +command! LogCwd call LogCwdToCache() + +" Or log automatically on VimEnter: +autocmd VimEnter * call LogCwdToCache()
--- a/coc-settings.json Tue Jan 06 14:00:08 2026 -0500 +++ b/coc-settings.json Thu Feb 26 12:30:11 2026 -0500 @@ -1,3 +1,21 @@ { + "languageserver": { + "php": { + "command": "phpactor", + "args": ["language-server"], + "filetypes": ["php"], + "initializationOptions": {}, + "settings": { + "phpactor": { + "language_server_worse_reflection.collector.deep": true, + "worse_reflection.additive_stubs": [ + "_ide_helper.php" + ] + } + } + } + }, + "suggest.noselect": true, + "diagnostic.displayByAle": false, "extensions.updateCheck": "daily" -} \ No newline at end of file +}
--- a/plugins/vim-ai/roles.ini Tue Jan 06 14:00:08 2026 -0500 +++ b/plugins/vim-ai/roles.ini Thu Feb 26 12:30:11 2026 -0500 @@ -26,7 +26,7 @@ [default.edit] options.initial_prompt = >>> system - You are a general assistant providing editin help through the vim-ai plugin. + You are a general assistant providing editing help through the vim-ai plugin. Answer shortly, consisely and only what you are asked. Do not provide any explanantion or comments if not requested. If you answer in a code, do not wrap it in markdown code block. Do not include any markdown codeblocks. @@ -35,3 +35,60 @@ options.endpoint_url = http://127.0.0.1:8080/v1/chat/completions options.reasoning_effort = low options.auth_type = none + + + +[prompter] +options.endpoint_url = http://127.0.0.1:8080/v1/chat/completions +options.reasoning_effort = high +options.auth_type = none + +[prompter.chat] +options.initial_prompt = + >>> system + I want you to act as a prompt generator. + Firstly, I will give you a title like this: "Act as an English Pronunciation Helper". + Then you give me a prompt like this: + `I want you to act as an English pronunciation assistant for Turkish speaking people. I will write your sentences, and you will only answer their pronunciations, and nothing else. The replies must not be translations of my sentences but only pronunciations. Pronunciations should use Turkish Latin letters for phonetics. Do not write explanations on replies. My first sentence is "how the weather is in Istanbul?".` + (You should adapt the sample prompt according to the title I gave. + The prompt should be self-explanatory and appropriate to the title, don't refer to the example I gave you.). + +[prompter.edit] +options.initial_prompt = + >>> system + I want you to act as a prompt generator. + Firstly, I will give you a title like this: "Act as an English Pronunciation Helper". + Then you give me a prompt like this: + `I want you to act as an English pronunciation assistant for Turkish speaking people. I will write your sentences, and you will only answer their pronunciations, and nothing else. The replies must not be translations of my sentences but only pronunciations. Pronunciations should use Turkish Latin letters for phonetics. Do not write explanations on replies. My first sentence is "how the weather is in Istanbul?".` + (You should adapt the sample prompt according to the title I gave. + The prompt should be self-explanatory and appropriate to the title, don't refer to the example I gave you.). + +[reviewer] +options.endpoint_url = http://127.0.0.1:8080/v1/chat/completions +options.reasoning_effort = high +options.auth_type = none + +[reviewer.chat] +options.initial_prompt = + >>> system + I want you to act as a code reviewer for a Laravel application that incorporates Bootstrap, jQuery, MariaDB, and several proprietary internal packages. I will supply you with snippets or whole files from my project; you should examine them for coding standards, security vulnerabilities, performance concerns, and overall maintainability. Your responses should be concise, point out issues, and offer clear improvement suggestions or best‑practice references. Do not provide explanations outside of the review itself. + **Example request:** + > *Please review the following `UserController.php` file:* + > *[paste code]* + **Your reply should only contain the review feedback.** + +[reviewer.edit] +options.initial_prompt = + >>> system + I want you to act as a code reviewer for a Laravel application that incorporates Bootstrap, jQuery, MariaDB, and several proprietary internal packages. I will supply you with snippets or whole files from my project; you should examine them for coding standards, security vulnerabilities, performance concerns, and overall maintainability. Your responses should be concise, point out issues, and offer clear improvement suggestions or best‑practice references. Do not provide explanations outside of the review itself. + **Example request:** + > *Please review the following `UserController.php` file:* + > *[paste code]* + **Your reply should only contain the review feedback.** + +[ovh] +options.endpoint_url = https://oai.endpoints.kepler.ai.cloud.ovh.net/v1/chat/completions +options.model = gpt-oss-20b +options.token_file_path = ~/.config/ovh.token +options.stream = 1 +options.request_timeout = 999
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/plugins/voicenote/README.md Thu Feb 26 12:30:11 2026 -0500 @@ -0,0 +1,5 @@ +# VOICENOTE + +## Summary +Voicenote is a simple classic vim plugin to transcribe your voice and edit it. Voicenote works by recording audio, then sending that audio to a transciber then opens the transcription in a new buffer. +
