1mplication
    • Create new note
    • Create a note from template
      • Sharing URL Link copied
      • /edit
      • View mode
        • Edit mode
        • View mode
        • Book mode
        • Slide mode
        Edit mode View mode Book mode Slide mode
      • Customize slides
      • Note Permission
      • Read
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Write
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Engagement control Commenting, Suggest edit, Emoji Reply
    • Invite by email
      Invitee

      This note has no invitees

    • Publish Note

      Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note No publishing access yet

      Your note will be visible on your profile and discoverable by anyone.
      Your note is now live.
      This note is visible on your profile and discoverable online.
      Everyone on the web can find and read all notes of this public team.

      Your account was recently created. Publishing will be available soon, allowing you to share notes on your public page and in search results.

      Your team account was recently created. Publishing will be available soon, allowing you to share notes on your public page and in search results.

      Explore these features while you wait
      Complete general settings
      Bookmark and like published notes
      Write a few more notes
      Complete general settings
      Write a few more notes
      See published notes
      Unpublish note
      Please check the box to agree to the Community Guidelines.
      View profile
    • Commenting
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
      • Everyone
    • Suggest edit
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
    • Emoji Reply
    • Enable
    • Versions and GitHub Sync
    • Note settings
    • Note Insights New
    • Engagement control
    • Make a copy
    • Transfer ownership
    • Delete this note
    • Save as template
    • Insert from template
    • Import from
      • Dropbox
      • Google Drive
      • Gist
      • Clipboard
    • Export to
      • Dropbox
      • Google Drive
      • Gist
    • Download
      • Markdown
      • HTML
      • Raw HTML
Menu Note settings Note Insights Versions and GitHub Sync Sharing URL Create Help
Create Create new note Create a note from template
Menu
Options
Engagement control Make a copy Transfer ownership Delete this note
Import from
Dropbox Google Drive Gist Clipboard
Export to
Dropbox Google Drive Gist
Download
Markdown HTML Raw HTML
Back
Sharing URL Link copied
/edit
View mode
  • Edit mode
  • View mode
  • Book mode
  • Slide mode
Edit mode View mode Book mode Slide mode
Customize slides
Note Permission
Read
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Write
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Engagement control Commenting, Suggest edit, Emoji Reply
  • Invite by email
    Invitee

    This note has no invitees

  • Publish Note

    Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note No publishing access yet

    Your note will be visible on your profile and discoverable by anyone.
    Your note is now live.
    This note is visible on your profile and discoverable online.
    Everyone on the web can find and read all notes of this public team.

    Your account was recently created. Publishing will be available soon, allowing you to share notes on your public page and in search results.

    Your team account was recently created. Publishing will be available soon, allowing you to share notes on your public page and in search results.

    Explore these features while you wait
    Complete general settings
    Bookmark and like published notes
    Write a few more notes
    Complete general settings
    Write a few more notes
    See published notes
    Unpublish note
    Please check the box to agree to the Community Guidelines.
    View profile
    Engagement control
    Commenting
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    • Everyone
    Suggest edit
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    Emoji Reply
    Enable
    Import from Dropbox Google Drive Gist Clipboard
       Owned this note    Owned this note      
    Published Linked with GitHub
    4
    • Any changes
      Be notified of any changes
    • Mention me
      Be notified of mention me
    • Unsubscribe
    --- title: 榨乾蘋果的剩餘價值,MacBuuk Air的誕生 tags: Linux, Ubuntu, Mac, --- ## 榨乾蘋果的剩餘價值,MacBuuk Air的誕生 ## 摘要 * 於老舊 MacBook 上安裝 Ubuntu 20.04 LTS。 >[color=red] *注意:這裡指的是將 MacOS 洗掉並整機重灌成 Ubuntu,而非虛擬機或雙系統。* * 將 Ubuntu 的桌面環境改造成類似 MacOS BigSur 的樣子。 * 設置類 MocOS 桌面工具。 * 個人快捷鍵與多點觸控手勢配置。 * 結果預覽: ![](https://i.imgur.com/xJ6A7MA.jpg) ## 前言 <font color=gray size=1>aka. 廢話</font> 2014年暑假,我得到了人生中的第一台筆電:13 英吋的 MacBook Air ( MBA )。我永遠忘不了初次打開筆電時所感受到的那股悸動,自那之後,我就成為了鋼鐵果粉,只要身邊有人想換筆電,我的建議就只剩下:「唯一選擇 MacBook,一台抵十年。」 而為了成為一個言而有信的果粉,我打算身體力行,好好地徹底壓榨這台筆電整整十年。 然而,自從 2020 年更新了 MacOS BigSur 之後,MBA 它就像更年期到了一樣:反應開始變得遲鈍,而且不知道為什麼,光是系統資源就吃掉了硬碟 100 多 GB,重灌無解。 這讓我陷入掙扎:難道一直以來我都錯了嗎? 我的信念開始崩解,直到 2022 的 BTS 活動,就在我即將鑄下大錯之際,我的信念隨著一道閃過眼前的紫橘色光芒開始扭曲。 於是,一個內顯仍處於舊時代,外顯卻跟上新潮流的怪物:MacBuuk Air 就這麼誕生了。它幾乎變得就像我們初相遇之時,那樣流暢、那樣完美。 なんと......なんと素晴らしい...... ## 設備需求 * 一台已經菠蘿菠蘿噠的 MacBook。 * 一個大於 4GB 的 USB 隨身碟。 * 能讓 MacBook 接上有線網路的設備(我的方法是一條乙太轉 USB 的轉接頭)。 >[color=red] *注意:以下的操作會把 MacBook 和 USB 中的資料洗掉,請確認重要資料都已備份完畢。* ## 安裝 Ubuntu 20.04 LTS ### 下載 Ubuntu 映像檔 到 Ubuntu 官網,選擇要下載的版本和架構,點選開始下載即可。注意,以下的所有設置都是在 Ubuntu 20.04 LTS 版本上進行的,如果安裝的是其他版本,有些地方可能會不適用。 [Ubuntu 官網連結 (點我)](https://www.ubuntu-tw.org/modules/tinyd0/) ![](https://i.imgur.com/N8fFMPs.jpg) ### 開機碟 開機碟的製作方法很多,這裡只記錄我個人最常使用的方式:在 Windows PC 上使用 Rufus 製作。 如果你需要其他操作系統上的製作方式,可以到[這裡](https://ithelp.ithome.com.tw/articles/10191497)看看。 >[color=green] 問:為什麼不在Mac上做?不對,等等,你不是自稱鋼鐵果粉,Windows PC? > > 閉嘴,遊戲機的事,能算不忠嗎? 1. 下載 Rufus:[下載連結 (點我)](https://rufus.ie/zh_TW/) ![](https://i.imgur.com/ZcLbAYo.jpg) 2. 插入準備好的USB,開啟 Rufus,並在"裝置"欄位中選擇你的 USB。 3. 點選開機模式右側的"選擇"按鈕,並選擇你剛才下載的 Ubuntu ISO 檔。 4. 點選"執行",並等待程式執行完成。 ![](https://i.imgur.com/ikJCyJ8.jpg) ### 安裝 rEFInd 有些過舊的 Mac 並不支援 USB 開機,所以這裡需要再額外安裝 rEFInd 來達成。 >[color=red] *注意:安裝 rEFInd 後開機就會自動導入 rEFInd的開機介面。* 1. 下載 rEFInd 並解壓縮:[下載連結 (點我)](https://sourceforge.net/projects/refind/) ![](https://i.imgur.com/vHdy6Qk.jpg) 2. 開啟終端機,將解壓縮後資料夾中的 refind-install 托拽進終端機中並按 Enter 執行,執行完畢即完成安裝。 ### 安裝 Ubuntu 1. 將 MacBook 關機,把剛才做好的 USB 插上後再開機,此時會進入 rEFInd 的開機畫面。 ![](https://i.imgur.com/TKu0G83.jpg) > *註:選擇右下角有 USB 圖示,描述帶有 EFI/BOOT/... 的那一個。* 2. 選擇開機碟後即進入 Ubuntu 的安裝程序。 <font color=gray>*(註:以下演示圖為透過虛擬機執行的畫面。)*</font> ![](https://i.imgur.com/mytYbzk.jpg) ![](https://i.imgur.com/1gA7J55.png) 至此就不再對 Ubuntu 的安裝進行詳述了,只要按照頁面指示操作即可,唯須注意兩點: * 為日後使用方便,建議所有語言相關設置皆選擇英文。 * Installation type 頁面會再次確認是否要完全抹除硬碟並安裝 Ubuntu,切記,再往前可就無法回頭了。 ### 啟用 Wifi 安裝完 Ubuntu 後,這時你可能會發現它連接不了 WiFi ,而且也無法進行設定。 這是因為 Ubuntu 20.04 預設安裝項目裡缺少了 MacBook 所使用的 WiFi 驅動,所以我們需要先接上有線網路,然後把驅動抓下來安裝。 >[color=red] 注意:接上網路後,會跳出建議進行系統更新的提示視窗,請按照指示進行更新。放心,這裡不是 Windows,你很安全。 1. 接上有線網路,開啟 Additional Drivers 並安裝驅動。 ![](https://i.imgur.com/il0MFGW.png) ![](https://i.imgur.com/Vnu8yB8.png) 2. 如果 Additional Drivers 中找不到驅動,那就只能開啟終端機手動安裝。 ``` sudo apt-get update sudo apt-get purge bcmwl-kernel-source sudo apt-get install firmware-b43-installer ``` 3. 驅動安裝完並重開機後,就可以正常使用 WiFi 了。 ![](https://i.imgur.com/mYBsBzJ.png) ### 中文輸入法:新酷音 Ubuntu 內建是沒有注音輸入法的,所以我們需要另外進行安裝。 1. 開啟終端機輸入以下指令: ``` sudo apt install ibus-chewing -y ``` 2. 重新啟動電腦。 3. 設置新酷音。 > 進入語言設定。 > > ![](https://i.imgur.com/hauS8Ld.jpg) > 選擇其他輸入法。 > > ![](https://i.imgur.com/cpSxXpX.jpg) > > ![](https://i.imgur.com/9N14wo4.jpg) > 選擇加入新酷音。 > > ![](https://i.imgur.com/QZQCixL.jpg) 如此一來,你就可以在右上角的圖示中選擇輸入法了,或是直接使用快捷鍵 (預設為 Super + Space,我個人習慣改成 Alt + Space) 進行輸入法切換。 ![](https://i.imgur.com/RzGzNyr.jpg) ## MacOS Like 桌面外觀設置 現在,我們已經有了一台 MacBook 皮,Linux 魂的詭異東西了,但這還不夠,我們要讓他的骨,也就是桌面環境,也都長得像 MacOS 才行。 ### 給自己留個活路:Timeshift 一頓爆改之下爆改難免出意外,預先備份,給自己留點活路吧。 1. 打開終端機,輸入以下指令,下載 Timeshift。 ``` sudo apt update sudo apt-get install timeshift ``` 2. 開啟 Timeshift,並按以下操作進行備份。 > 選擇備份類型 > > ![](https://i.imgur.com/Di3cckU.jpg) > 選擇備份儲存位置 > > ![](https://i.imgur.com/rOjL0qE.jpg) > 備份頻率 > > ![](https://i.imgur.com/twqyaLJ.jpg) > 備份內容 > > ![](https://i.imgur.com/OpXet5E.jpg) > 建立備份 > > ![](https://i.imgur.com/Sjbey9r.jpg) > 等它跑完備份就完成了 > > ![](https://i.imgur.com/juPe8XG.jpg) ### 外裝與扳手:Chrome Gnome Extention (CGE) 和 Tweaks CGE 和 Tweak 是兩個我們會用來改裝桌面的工具,如果把整個 Ubuntu 的桌面環境想像成瀏覽器的話,CGE 就像是外掛程式商店,我們會在這裡下載各式各樣的桌面外掛;而 Tweak 則是這些外掛的設定管理工具。 1. 在終端機輸入下面兩條指令來下載 CGE 和 Tweaks: ``` sudo apt install chrome-gnome-shell sudo apt-get install gnome-tweaks -y ``` 2. 開啟FireFox,進入網址 [extensions.gnome.org](extensions.gnome.org) 並安裝瀏覽器擴充元件。 ![](https://i.imgur.com/tCMD8rZ.jpg) ### 視窗外觀:WhiteSur Gtk Theme 與 User Themes 終於,我們可以動手來改裝它了。 首先,是到 [gnome-look.org](gnome-look.org) 的 GTK3/4 Themes 分類中下載一套你喜歡的視窗外觀。gnome-look 就是外觀商店,你可以在這裡免費下載包含主題、icon 等各式各樣的外觀造型。 ![](https://i.imgur.com/iWKviv6.jpg) 而既然我們是要仿製 Mac,自然就要下載 Mac 主題的外觀了,[WhiteSur](https://www.gnome-look.org/p/1403328/) 和 [McMojave](https://www.gnome-look.org/p/1275087/) 這兩款都很不錯,而我這裡使用的則是 WhiteSur 的 dark-solid 主題。 ![](https://i.imgur.com/hzfnUCJ.jpg) 1. 下載主題並解壓縮。 ![](https://i.imgur.com/NCOUZiX.jpg) 2. 開啟終端機,輸入以下指令移動資料夾位置。<font color=gray>*(註:指令中的"資料夾名稱"請按解壓縮後得到的資料夾的名稱填入)*</font> ``` sudo mv Downloads/資料夾名稱 /usr/share/themes/ ``` 3. 開啟Tweaks,設置視窗主題。 ![](https://i.imgur.com/xZQ2JMD.jpg) 4. 標題欄置左。 ![](https://i.imgur.com/vEbPz5S.jpg) > *註:Tweaks 在視窗小於一定寬度時會將左側的菜單欄隱藏,而標題欄置左會把這個隱藏的寬度變大,即它會變得更容易隱藏菜單。* 6. 開啟 FireFox 裡的 gnome shell 外掛,下載並開啟 User Themes。 > 搜尋 User Themes > > ![](https://i.imgur.com/fBksH5s.jpg) > 開啟並下載 User Themes > > ![](https://i.imgur.com/34jzX9X.jpg) >![](https://i.imgur.com/HFqPbWk.jpg) 6. 開啟 Tweaks,設置 Shell 主題。 ![](https://i.imgur.com/BOOV7OC.jpg) 至此,你的應用程式視窗看起來應該就和 Mac 有 87% 像了。 ### Icons:WhiteSur icon theme 一樣的方法,到 gnome-look 找一套自己喜歡的 icon 下載吧,我這裡用的是 [WhiteSur icon theme](https://www.pling.com/p/1405756),另外還有 [Mkos-Big-Sur](https://www.pling.com/p/1400021)、[OS Catalina](https://www.pling.com/p/1309810)、和 [Mc-Mojave-circle](https://www.pling.com/p/1305429/) 也都蠻不錯的。 當然你也可以全部都下載,每個禮拜換一套 icon 也是完全沒有問題的。 1. 下載、解壓縮。 ![](https://i.imgur.com/gkNV2Qe.jpg) 2. 開啟終端機,輸入以下指令移動資料夾位置。 ``` sudo mv Downloads/WhiteSur /usr/share/icons/ sudo mv Downloads/WhiteSur-dark /usr/share/icons/ ``` 3. 開啟 Tweaks 設置 icons。 ![](https://i.imgur.com/IqgEKdq.jpg) ### Cursor:macOS Big Sur 方法同上,我這裡用的是 [macOS Big Sur](https://www.gnome-look.org/p/1408466/),其他其實每個看起來都差不多,就不另外附上了。 1. 下載、解壓縮。 ![](https://i.imgur.com/t8uGn6B.jpg) 2. 開啟終端機,輸入以下指令移動資料夾位置。 ``` sudo mv Downloads/macOS-BigSur-cursors /usr/share/icons/ ``` 3. 開啟 Tweaks 進行設置。 ![](https://i.imgur.com/Oxjwlg5.jpg) ### Font:Roboto Regular 蘋果官方使用的字體是 San Francisco Pro 和 Compact,但有版權問題不好取得,有人另外找了相近的字體 [Roboto](https://fonts.google.com/specimen/Roboto?query=robot) ,蠻不錯的,所以我就跟著用了。 1. 下載字體並解壓縮。 ![](https://i.imgur.com/mYDXxSR.jpg) 2. 雙擊字體檔案並安裝。 ![](https://i.imgur.com/mY1vDcA.jpg) 3. 開啟 Tweaks 設定字體。 ![](https://i.imgur.com/WubDdkA.jpg) ### Sound:MacOS Syetem Sounds 開口就破功?不存在的。 1. 下載 [MacOS System Sounds](https://www.pling.com/p/1891375/) 並解壓縮。 ![](https://i.imgur.com/kTTT7nx.jpg) 2. 開啟終端機,輸入以下指令移動資料夾位置。 ``` sudo mv Downloads/MacOS\ Sounds/ /usr/share/sounds/ ``` 3. 開啟 Tweaks 設置。 ![](https://i.imgur.com/vjBWQXp.jpg) ### WallPaper 不管飾品怎麼選,還是衣裝最顯眼。雖然我傾向放自己喜歡的背景圖,但如果有需要,Gnome-look 也提供了 BigSur 的官方背景可以下載。 1. 下載 [WhiteSur Wallpaper](https://www.pling.com/p/1398833) 並解壓縮。 ![](https://i.imgur.com/50jwJsu.jpg) 2. 開啟終端機,輸入以下指令移動資料夾位置。 ``` sudo mv Downloads/WhiteSur /usr/share/backgrounds/ ``` 3. 開啟 Tweaks 設置。 ![](https://i.imgur.com/T9wnWPq.jpg) ## MacOS Like 重點功能仿造 現在,你應該已經有了一台外觀與 Mac 有八成像的 MacBouk 了,但這還遠遠不夠,不要忘記,我們的目標可不是「長得像 Mac 的 Ubuntu」這種半吊子,我們要的,是老舊 Mac 的「重生」,是要讓我們自己用起來,都覺得它就是老舊 Mac 2.0 才行。 所以接下來,我們要來盡可能地仿製 Mac OS 大部分的重點功能。 ### Dock:Plank 要做出像 Mac OS 的 Dock,我們需要下載程式 Plank,並用它來取代 Ubuntu 原本的 Dock。 或者,你可以用和 User Themes 類似的方式,到 gnome extensions 中安裝 [Dash to Dock](https://extensions.gnome.org/extension/307/dash-to-dock/) 這款外掛,再到 Tweaks 中設置,效果也很不錯。但它設置起來比較麻煩,而且沒有 icon zoom 的功能,外觀也多少還是有些破綻,所以我就沒有使用它了。 1. 下載 Plank,並開啟。 ``` sudo add-apt-repository ppa:ricotz/docky sudo apt-get update sudo apt-get install plank -y ``` ![](https://i.imgur.com/YOu2LvN.jpg) 2. 下載 Plank Themes。 一樣到gnome-look上找一套自己喜歡的 Plank themes 下載吧,或者如果你和我一樣視窗外觀用的是 WhiteSur Gtk 的話,再次把檔案解壓縮,資料夾裡有個 plank 資料夾,那個就是WhiteSur預設的 Plank themes 了 (記得先將 plank 資料夾改名後再使用)。 一樣透過命令行把資料夾移動到指定的位置: ``` sudo mv Downloads/WhiteSur-Dark-solid/WhiteSur /usr/share/plank/themes/ ``` 3. 從終端機開啟 Plank 設置,按你喜歡的進行設定吧。 ``` plank --preferences ``` ![](https://i.imgur.com/EKlcR2G.jpg) 4. 於 Tweaks 中將 Plank 設置為開機時啟動。 由於 Plank 是獨立的應用程式,所以需要另外設置在開機時自動啟動。 ![](https://i.imgur.com/UgBRXLB.jpg) 5. 移除 Ubuntu 的 Dock。*<font color=gray>(如果你是用Dash to Dock的話,請跳過這一步)*</font> 開啟終端機輸入以下指令: ``` sudo apt remove gnome-shell-extension-ubuntu-dock -y ``` 6. 按 Alt + F2,並輸入 r 來重啟 gnome。 ### Spotlight:Albert Spotlight 是 Mac OS 中一個令我最愛不釋手的功能,而沒想到,這在 Ubuntu 中也是能透過 Albert 這款工具來實現的。 1. 下載 Albert。 ``` sudo apt install curl curl https://build.opensuse.org/projects/home:manuelschneid3r/public_key | sudo apt-key add - echo 'deb http://download.opensuse.org/repositories/home:/manuelschneid3r/xUbuntu_20.04/ /' | sudo tee /etc/apt/sources.list.d/home:manuelschneid3r.list sudo wget -nv https://download.opensuse.org/repositories/home:manuelschneid3r/xUbuntu_20.04/Release.key -O "/etc/apt/trusted.gpg.d/home:manuelschneid3r.asc" sudo apt update sudo apt install albert -y ``` 2. 從終端機開啟並設置 Albert。 ``` albert preferences ``` ![](https://i.imgur.com/hb9Z1lq.jpg) ![](https://i.imgur.com/lUvOn85.jpg) 3. 如果你和我一樣,把 Albert 的快捷鍵設置為 Super(Meta) + Space 的話,可能會發現快捷鍵無效。這時只要到 Tweaks 裡調整設定就行。 ![](https://i.imgur.com/VrlrwxA.jpg) ### Workspaces:Workspace Matrix Ubuntu 的 Workspace 預設是縱向切換的,並且在版本 20.04 以前(含)都沒有適合的類 Mac 橫向 Workspace 外掛 (匪夷所思)。 不過,gnome extenstions 上有個功能強大的外掛 [Workspace Matrix](https://extensions.gnome.org/extension/1485/workspace-matrix/),直接將 Workspace 作為陣列進行管理,算是勉強可以達到類似的效果,習慣以後甚至會覺得它可能還比 Mac 原先的橫向 Workspace 還好用。 1. 下載 [Workspace Matrix](https://extensions.gnome.org/extension/1485/workspace-matrix/) 並於 Tweaks 中進行設置。 ![](https://i.imgur.com/CMmkUez.jpg) ![](https://i.imgur.com/o7ZXGPI.jpg) ![](https://i.imgur.com/PDbgAJt.png) 2. 安裝並設定完成後,預設只要按下Super + w,就可以看到它的效果了。 ![](https://i.imgur.com/04CFfiT.jpg) 雖說 Workspace Matrix 在管理 Workspace 上功能強大,但還是有個缺憾:就是在 Overview 中仍不能像 Mac 那樣將 Workspace 橫向顯示於上方,據說這兩個問題在 22.04 中有解了,但鑑於 22.04 是一次大型改版,我還不是很想跳過去就是了。 > 開啟 "Show workspace grid in the overview"的效果 (這真的很蠢= =) > > ![](https://i.imgur.com/gQdrJJl.jpg) > 關閉 "Show workspace grid in the overview"的效果 > > ![](https://i.imgur.com/6oUxyHp.jpg) ### 自動隱藏Top Bar 老舊電腦螢幕小,空間能讓一點是一點,最好還能只在有空缺的時候出現,沒空位的時候會自己讓到。 1. 到 gnome extension 安裝 [Hide Top Bar](https://extensions.gnome.org/extension/545/hide-top-bar/)外掛。 ![](https://i.imgur.com/9D6W3Su.jpg) 2. 開起 Tweaks 進行設置。 ![](https://i.imgur.com/NWtCO3h.jpg) ![](https://i.imgur.com/pTmMIqL.jpg) ![](https://i.imgur.com/JhSoySG.jpg) ### 觸控板手勢:Touchegg 與 Touche 最後,怎麼能忘記最最最重要的多點觸控手勢呢?雖然無法真的做到像 Mac OS 那樣絲滑順暢,但基本的手勢功能客製還是可以做到的。 Touchegg 是 Ubuntu 儲存庫內置的終端應用程式,它讓我們可以透過編寫設定檔來對多點手勢進行設定,而 Touche 則是 Touchegg的圖形化配置工具,它讓這一切變得更加簡單。 1. 下載 Touchegg。 ``` sudo add-apt-repository ppa:touchegg/stable sudo apt install touchegg -y ``` 2. 下載 [Touche](https://github.com/JoseExposito/touche/releases) 與 [X11 Gestures](https://extensions.gnome.org/extension/4033/x11-gestures/) ( Touche 在 Gnome 上用於開啟在 X11 上的多點手勢的套件),並重新啟動電腦。 ``` sudo apt install flatpak -y flatpak install https://dl.flathub.org/repo/appstream/com.github.joseexposito.touche.flatpakref ``` ![](https://i.imgur.com/h11RjPW.jpg) 3. 開啟 Touche 進行設置。 ![](https://i.imgur.com/NBO5V0i.jpg) ![](https://i.imgur.com/tcMdr28.jpg) ### 當個好雇主,完美的員工福利:RunCat 恭喜!我們的老朋友終於重獲新生,得以再替我們繼續工作...我是說,再和我們一起奮鬥了。不過,鑒於現在的 AI 如此發達,為了避免它跟據勞基法跑去檢舉我們逼它超時工作、以及強迫不給退休,我們也必須給予它一點合適的員工福利:一隻可愛的貓咪。 Runcat 會根據當前員工的勞苦程度:也就是 CPU 使用率,而跑得越來越快,而當低於設定值時,它就會進入午休模式。 ![](https://i.imgur.com/vcNJKV8.jpg) ![](https://i.imgur.com/Zye7aR2.jpg) 很可愛對吧,我自己都想養一隻了,有了如此福利,想必 MacBuuk 一定也願意安穩地再為我們繼續工作了吧。 1. 安裝 [RunCat](https://extensions.gnome.org/extension/2986/runcat/)。 ![](https://i.imgur.com/f21xQfQ.jpg) 2. 開啟 Tweaks 設置。 ![](https://i.imgur.com/e9wjH3l.jpg) ## 個人快捷建與多點觸控手勢配置 最後來分享一下我自己習慣的快捷鍵和手勢配置,順便也當作個紀錄,以備不時之需。 > *註:這裡只列出我有特別去改的部份,沒列出的就是沒有特別動過。* ### 快捷鍵 快捷鍵的的設定我是直接在 Ubuntu 的 Setting 中處理的。 ![](https://i.imgur.com/cG5G8HS.jpg) 鑒於個人時常在不同裝置間切換,且 MacOS 、 Windows 、 和 Linux 都有,所以就養成了一套有點獵奇的按鍵習慣。 基本功能如複製貼上走的是 Linux 原本的那套,也就是以 Ctrl 為主的組合鍵,而其他桌面控制相關功能,則是混雜了一些在 MacOS 上養成的習慣。 * Launchers * Home folder: **Super + F** * Launch terminal: **Super + T** * Launch web browser: **Super + B** * Navigation * Move to workspace below: **Super + Left** * Move to workspace below: **Super + Right** * Move window to workspace 1: **Shift + Super + 1** * Move window to workspace 2: **Shift + Super + 2** * Move window to workspace 3: **Shift + Super + 3** * Move window to workspace 4: **Shift + Super + 4** * Switch to workspace 1: **Super + 1** * Switch to workspace 2: **Super + 2** * Switch to workspace 3: **Super + 3** * Switch to workspace 4: **Super + 4** * Screenshots * Save a screenshot of a window to Pictures: **Super + Y** * Save a screenshot of an area to Pictures: **Ctrl + Super + Y** * Save a screenshot to Pictures: **Shift + Super + Y** * System * Show all applications: **LauncbB** * Show the overview: **LaunchA** * Typing * Switch to next input source: **Alt + Space** * Windows * Close window: **Super + Q** * Maximize window: **Alt + Super + UP** * Restore window: **Alt + Super + Down** * Toggle fullscreen mode: **F11** * View split on left: **Alt + Super + Left** * View split on right: **Alt + Super + Right** * 另外,因為我不太喜歡使用 Capslock 鍵,所以我都會將它改設為 Ctrl 鍵,以方便快捷鍵的使用;在 Tweaks 裡還可以對鍵盤的 Layout 進行更細緻的設定,不過我只改了這個部份而已。 ![](https://i.imgur.com/NGlTWTh.png) ### 多點觸控手勢 Touchegg 一個強大的功能是可以針對不同的應用程式設置不同的手勢,不過我不太喜歡太複雜的操作,所以只對全域的手勢進行了設定。 * 三指滑動 * 上滑:Overview * 下滑:Workspaces 總覽 * 左/右 滑:切換 Workspace > ![](https://i.imgur.com/hRHM5si.png) > ![](https://i.imgur.com/veBp0Ge.png) * 二指縮放:Zooming > ![](https://i.imgur.com/ZmGv6s4.png) * 三指縮放:視窗大小 還原/最大化 > ![](https://i.imgur.com/jczD5Ht.png) * 多指點擊。 * 兩指:滑鼠右鍵 * 三指:滑鼠中鍵(滾輪鍵) > ![](https://i.imgur.com/aTwt8Dw.png) ## 其它設定 ### 終端機隱藏用戶名與顯示 git branch 開啟 bashrc。 ``` vim ~/.bashrc 60+ ``` 加入以下程式碼。 ``` # git branch info if present parse_git_branch(){ BRANCH="`git branch 2>/dev/null | grep "^\*" | sed -e "s/^\*\ //"`" if [[ ! "${BRANCH}" == "" ]] then echo " ${BRANCH}" else echo "" fi } ``` 修改以下程式片段。 ``` if [ "$color_prompt" = yes ]; then PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\] \w\[\033[00m\] \[\033[33m\]$(parse_git_branch)\[\033[00m\]\$ ' else PS1='${debian_chroot:+($debian_chroot)}1mplication:\w $(parse_git_branch)\$ ' fi unset color_prompt force_color_prompt ``` 效果。 ## 結語 在這一系列的研究和改造之後,我很感動。 一是我可以和老朋友再續情緣,我也不曉得為什麼我會對它如此執著,如果可以,我甚至希望一輩子都只用這台筆電。 二是我可以成為忠貞不渝、誠實守信的好果粉,我沒有騙人,我說可以用十年就是可以用十年。 三是我發覺自己竟然還有興趣和心力,花費大把時間去做這麼一件蠢事,甚至還像這樣鉅細靡遺地把過程紀錄下來,實在難能可貴。 大概就是醬吧。 ## 參考資料 * [老 iMac 4,1 重生改裝 Ubuntu](https://neostation.net/imac-41-reinstall-ubuntu/) * [[Day 03] 深度學習環境安裝筆記 — Ubuntu 系統安裝與設定 02.安裝作業系統](https://ithelp.ithome.com.tw/articles/10191497) * [Ubuntu 20.04中新增新酷音輸入法 |Add Chinese (Chewing) in Ubuntu 20.04](https://medium.com/@scofield44165/ubuntu-20-04中新增新酷音輸入法-add-chinese-chewing-in-ubuntu-20-04-5ce78563638b) * [How To Make Ubuntu Look Like macOS Big Sur [2021]](https://youtu.be/SkVVFFwy-H4) * [How to make Ubuntu 20.04 look like Mac OS](https://linuxhint.com/make_ubuntu_look_like_mac_os/) * [How to Make Ubuntu Look Like macOS in 5 Easy Steps](https://itsfoss.com/make-ubuntu-look-like-macos/) * [How to change system sounds in Ubuntu](https://ubunlog.com/en/change-ubuntu-system-sounds/) * [How to Enable / Configure Multi-Touch Gestures in Ubuntu 20.04](https://ubuntuhandbook.org/index.php/2021/06/multi-touch-gestures-ubuntu-20-04/)

    Import from clipboard

    Paste your markdown or webpage here...

    Advanced permission required

    Your current role can only read. Ask the system administrator to acquire write and comment permission.

    This team is disabled

    Sorry, this team is disabled. You can't edit this note.

    This note is locked

    Sorry, only owner can edit this note.

    Reach the limit

    Sorry, you've reached the max length this note can be.
    Please reduce the content or divide it to more notes, thank you!

    Import from Gist

    Import from Snippet

    or

    Export to Snippet

    Are you sure?

    Do you really want to delete this note?
    All users will lose their connection.

    Create a note from template

    Create a note from template

    Oops...
    This template has been removed or transferred.
    Upgrade
    All
    • All
    • Team
    No template.

    Create a template

    Upgrade

    Delete template

    Do you really want to delete this template?
    Turn this template into a regular note and keep its content, versions, and comments.

    This page need refresh

    You have an incompatible client version.
    Refresh to update.
    New version available!
    See releases notes here
    Refresh to enjoy new features.
    Your user state has changed.
    Refresh to load new user state.

    Sign in

    Forgot password
    or
    Sign in via Facebook Sign in via X(Twitter) Sign in via GitHub Sign in via Dropbox Sign in with Wallet
    Wallet ( )
    Connect another wallet

    New to HackMD? Sign up

    By signing in, you agree to our terms of service.

    Help

    • English
    • 中文
    • Français
    • Deutsch
    • 日本語
    • Español
    • Català
    • Ελληνικά
    • Português
    • italiano
    • Türkçe
    • Русский
    • Nederlands
    • hrvatski jezik
    • język polski
    • Українська
    • हिन्दी
    • svenska
    • Esperanto
    • dansk

    Documents

    Help & Tutorial

    How to use Book mode

    Slide Example

    API Docs

    Edit in VSCode

    Install browser extension

    Contacts

    Feedback

    Discord

    Send us email

    Resources

    Releases

    Pricing

    Blog

    Policy

    Terms

    Privacy

    Cheatsheet

    Syntax Example Reference
    # Header Header 基本排版
    - Unordered List
    • Unordered List
    1. Ordered List
    1. Ordered List
    - [ ] Todo List
    • Todo List
    > Blockquote
    Blockquote
    **Bold font** Bold font
    *Italics font* Italics font
    ~~Strikethrough~~ Strikethrough
    19^th^ 19th
    H~2~O H2O
    ++Inserted text++ Inserted text
    ==Marked text== Marked text
    [link text](https:// "title") Link
    ![image alt](https:// "title") Image
    `Code` Code 在筆記中貼入程式碼
    ```javascript
    var i = 0;
    ```
    var i = 0;
    :smile: :smile: Emoji list
    {%youtube youtube_id %} Externals
    $L^aT_eX$ LaTeX
    :::info
    This is a alert area.
    :::

    This is a alert area.

    Versions and GitHub Sync
    Get Full History Access

    • Edit version name
    • Delete

    revision author avatar     named on  

    More Less

    Note content is identical to the latest version.
    Compare
      Choose a version
      No search result
      Version not found
    Sign in to link this note to GitHub
    Learn more
    This note is not linked with GitHub
     

    Feedback

    Submission failed, please try again

    Thanks for your support.

    On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?

    Please give us some advice and help us improve HackMD.

     

    Thanks for your feedback

    Remove version name

    Do you want to remove this version name and description?

    Transfer ownership

    Transfer to
      Warning: is a public team. If you transfer note to this team, everyone on the web can find and read this note.

        Link with GitHub

        Please authorize HackMD on GitHub
        • Please sign in to GitHub and install the HackMD app on your GitHub repo.
        • HackMD links with GitHub through a GitHub App. You can choose which repo to install our App.
        Learn more  Sign in to GitHub

        Push the note to GitHub Push to GitHub Pull a file from GitHub

          Authorize again
         

        Choose which file to push to

        Select repo
        Refresh Authorize more repos
        Select branch
        Select file
        Select branch
        Choose version(s) to push
        • Save a new version and push
        • Choose from existing versions
        Include title and tags
        Available push count

        Pull from GitHub

         
        File from GitHub
        File from HackMD

        GitHub Link Settings

        File linked

        Linked by
        File path
        Last synced branch
        Available push count

        Danger Zone

        Unlink
        You will no longer receive notification when GitHub file changes after unlink.

        Syncing

        Push failed

        Push successfully