1. 程式人生 > >ubuntu安裝谷歌拼音輸入法, ubuntu 軟體更新源 source.list, package無法找到安裝,ubuntu system setting問題: ubuntu desktop 安裝

ubuntu安裝谷歌拼音輸入法, ubuntu 軟體更新源 source.list, package無法找到安裝,ubuntu system setting問題: ubuntu desktop 安裝

(一)安裝谷歌輸入法可以按照如下連結:

http://blog.csdn.net/arackethis/article/details/42154029

問題的關鍵在於,筆者覺得沒必要那麼麻煩,直接:

1.

sudo apt-get install fcitx fcitx-config-gtk fcitx-sunpinyin fcitx-googlepinyin fcitx-module-cloudpinyin

如果奏效也是可以的, fcitx-googlepinyin就是要安裝的輸入法,當然也可以安裝ibus的谷歌輸入法。

2.

進入system setting的Language Support, 將鍵盤輸入方式input method改成fcitx, 然後重啟電腦, 進入系統後發現螢幕右上角出現了新的鍵盤圖示,點選config,點選‘+’,搜尋googlepinyin, 將我們安裝的輸入法選中新增,即可。

(二)軟體更新源列表 source.list

RT, 在安裝谷歌輸入法後踩到坑了,有的帖子推薦刪除原來的ibus和之前自己安裝的fcitx。但是問題來了?

比如解除安裝了fcitx後system setting 沒有了。system setting其實是Ubuntu的圖形桌面,有的情況下是setting裡的選項不完整了。這個是一個連鎖反應,當直接執行:

sudo apt-get install ubuntu-desktop 時,報錯如下

Package 'ubuntu-desktop' has no installation candidate, 或者是 can not locate package, package is not available要安裝的package breakup, enable the "Universe" respository等問題 (關於要安裝的package失敗報錯


按照有些經驗執行:

sudo apt-get update後問題依然存在,無法安裝。

出現此錯誤的原因是預設的Ubuntu 14.04或者其他系列系統的更新軟體源太舊了,不能定位到需要安裝的包,此時需要重新更新source.list

方法如下:

1.可選:備份一下原始檔案

sudo cp /etc/apt/sources.list /etc/apt/sources.list_backup
2.
sudo gedit /etc/apt/sources.list
將如下內容貼上複製進去:

## 阿里巴巴的軟體更新源,當然也可以選擇其他(http://blog.csdn.net/wang_shuai_ww/article/details/46679081


deb http://mirrors.aliyun.com/ubuntu/ trusty main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ trusty-security main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ trusty-updates main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ trusty-proposed main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ trusty-backports main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ trusty main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ trusty-security main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ trusty-updates main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ trusty-proposed main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ trusty-backports main restricted universe multiverse

3. 

sudo apt-get update

然後正常進行package的安裝或者更新

(三)修復或者重新安裝 system setting/ ubuntu desktop

進行步驟(二)之後,執行以下命令:

sudo apt-get update

sudo apt-get install ubuntu-desktop 

此命令立刻有效,無需重啟

填坑愉快