No description
  • Vim Script 100%
Find a file
2024-12-19 07:43:40 +07:00
autoload first commit 2024-12-19 00:15:14 +07:00
plugin first commit 2024-12-19 00:15:14 +07:00
LICENSE first commit 2024-12-19 00:15:14 +07:00
README.md fix typos 2024-12-19 07:43:40 +07:00

fsay

Simple vim9 plugin for text to speech. This is a wrapper of piper.

Installation

Using vim-plug

Add this to .vimrc

Plug 'https://codeberg.org/jonesangga/fsay.git'

reload .vimrc and then :PlugInstall to install.

Manual

Clone this repo outside your ~/.vim/plugin/ directory, say to ~/.vim/fafovim/

git clone --depth 1 https://codeberg.org/jonesangga/fsay.git

Add this to your .vimrc

set runtimepath+=~/.vim/fafovim/fsay/

Usage

Set your piper binary and model path in .vimrc, for example

let g:piper_bin = '~/Piper/piper/piper'
let g:piper_model = '~/Piper/en_US-hfc_male-medium.onnx'

The default mapping is <leader>s.

If you are in visual mode, it will speak the selected text. Actually it first yanked the text and then call the related function.

If you are in normal mode, it will speak the last yanked text.

Or use your own mapping, for example:

nmap <leader>x <Plug>(fsay-say-yanked)

See also

vim-piper