應用程序啟動器 “sublime_text.desktop“ 還沒有被標記為 信任。如果您不知道這個文件的來源,那麽啟動它可能會不安全。解決sublime在ubuntu中不支持中文輸入問題。
阿新 • • 發佈:2018-06-23
Go fix sudo ons 啟動 show -- ica 完美
1.下載
git clone https://github.com/lyfeyaj/sublime-text-imfix.git
2.進行一些處理
cd ~/sublime-text-imfix
sudo cp ./lib/libsublime-imfix.so /opt/sublime_text/
sudo cp ./src/subl /usr/bin/
這樣每次都要輸入subl才能打開,很不友好。
對Desktop文件進行改造,可以完美解決中文輸入。
原來的
[Desktop Entry] Version=1.0 Type=Application Name=Sublime Text GenericName=Text Editor Comment=Sophisticated text editor for code, markup and prose Exec=/opt/sublime_text/sublime_text %F Terminal=false MimeType=text/plain; Icon=sublime-text Categories=TextEditor;Development; StartupNotify=true Actions=Window;Document; [Desktop Action Window] Name=New Window Exec=/opt/sublime_text/sublime_text -n OnlyShowIn=Unity; [Desktop Action Document] Name=New File Exec=/opt/sublime_text/sublime_text --command new_file OnlyShowIn=Unity;
改造後的
[Desktop Entry] Version=1.0 Type=Application Name=Sublime Text GenericName=Text Editor Comment=Sophisticated text editor for code, markup and prose Exec=bash -c "LD_PRELOAD=/opt/sublime_text/libsublime-imfix.so exec /opt/sublime_text/sublime_text %F" Terminal=false MimeType=text/plain; Icon=sublime-text Categories=TextEditor;Development; StartupNotify=true Actions=Window;Document; [Desktop Action Window] Name=New Window Exec=bash -c "LD_PRELOAD=/opt/sublime_text/libsublime-imfix.so exec /opt/sublime_text/sublime_text -n" OnlyShowIn=Unity; [Desktop Action Document] Name=New File Exec=bash -c "LD_PRELOAD=/opt/sublime_text/libsublime-imfix.so exec /opt/sublime_text/sublime_text --command new_file" OnlyShowIn=Unity;
應用程序啟動器 “sublime_text.desktop“ 還沒有被標記為 信任。如果您不知道這個文件的來源,那麽啟動它可能會不安全。解決sublime在ubuntu中不支持中文輸入問題。