From 67a73dda4fb24b1b8e9c5f61e03c00a5dd458f5e Mon Sep 17 00:00:00 2001 From: zeertzjq Date: Mon, 20 Sep 2021 20:40:44 +0800 Subject: [PATCH] Do not run fcitx5-remote in a shell --- plugin/fcitx.vim | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/plugin/fcitx.vim b/plugin/fcitx.vim index 9b4d47c..9d4547f 100644 --- a/plugin/fcitx.vim +++ b/plugin/fcitx.vim @@ -11,19 +11,19 @@ endif let s:keepcpo = &cpo set cpo&vim -" If g:fcitx5_remote is set (to the path to `fcitx5-remove`), use it to toggle IME state. +" If g:fcitx5_remote is set (to the path to `fcitx5-remote`), use it to toggle IME state. if exists("g:fcitx5_remote") function Fcitx2en() - let inputstatus = trim(system(g:fcitx5_remote)) + let inputstatus = trim(system([g:fcitx5_remote])) if inputstatus == '2' let b:inputtoggle = 1 - call system(g:fcitx5_remote . ' -c') + call system([g:fcitx5_remote, '-c']) endif endfunction function Fcitx2zh() try if b:inputtoggle == 1 - call system(g:fcitx5_remote . ' -o') + call system([g:fcitx5_remote, '-o']) let b:inputtoggle = 0 endif catch /inputtoggle/