全新 Windows Terminal 簡介

全新 Windows Terminal 簡介

作者: Dan Franciscus
發布日期: 九月 24, 2019 0 Comments

Microsoft 公司在最近一次的 Microsoft Build 大會上宣佈推出一款全新的 Windows 終端機,名稱是 Windows Terminal,能夠取代 PowerShell 的 cmd。

長久以來,Windows 使用者對於 Windows 作業系統內建的終端機多有抱怨,我自己也感同身受。Windows 10 類似 macOS,是一款設計得不錯的作業系統,但相較之下,macOS 用起來更加俐落,是更符合現代設計的終端機。除了有大量的設定、主題外,當然也少不了分頁。Windows 欠缺符合時勢所趨的終端機,這一點始終為人詬病,許多命令列使用者也因此另謀他法,改用諸如 ConEmu 之類的其他終端機,這些終端機提供的功能更現代化,也更符合使用者的喜好。

背景資訊

Windows 主控台 (conhost.exe) 的設計向來不忘「回溯相容性」這個目標,卻也因此侷限了能夠隨著時間發展而新增的功能。主控台負責轉譯文字、輸入引擎以及使用者偏好設定等功能。為解決這個問題,Windows 命令列團隊重新設計了主控台,讓 Windows Terminal 能與主控台共用元件。若想深入瞭解這方面的資訊,建議您收聽 RunAsRadio 播放的 Rich Turner 訪談內容。Rich 針對 Windows 主控台的功能以及 Windows Terminal 的推出緣由發表了非常精采的見解。windows terminal 1

安裝作業

Microsoft 初次發佈 Windows Terminal 時 (別忘了現在是預覽版),要在系統上進行安裝,唯一的方法就是運用 Github 提供的原始程式碼編輯,感覺非常麻煩,所以我一直避免這麼做。現在,直接透過 Windows Store 或使用 Chocolatey 就能安裝了。我是 Chocolatey 愛用者,自然樂見這種安裝方式。

使用 Chocolatey 安裝 Windows 終端機,只要一個命令就行了:

choco install microsoft-windows-terminal -y

別忘了,作業系統必須至少是 Windows 10 的 1903 版才能安裝這款終端機。

特色

Windows Terminal 的第一項特點讓我很開心,那就是分頁。對 Windows 使用者而言,分頁也許是最重要的一項特點。依預設,Windows Terminal 的開啟方式是使用 PowerShell Core,有了分頁功能之後,使用 cmd 和 Windows PowerShell 也能開啟 Windows Terminal。使用者總算能夠同時開啟多個 PowerShell 工作階段,不必再管理多到不行的 Windows。這真是太棒了!windows terminal 2

{

            "acrylicOpacity" : 0.5,

            "background" : "#012456",

            "closeOnExit" : true,

            "colorScheme" : "Campbell",

            "commandline" : "powershell.exe",

            "cursorColor" : "#FFFFFF",

            "cursorShape" : "bar",

            "fontFace" : "Consolas",

            "fontSize" : 10,

            "guid" : "{61c54bbd-c2c6-5271-96e7-009a87ff44bf}",

            "historySize" : 9001,

            "icon" : "ms-appx:///ProfileIcons/{61c54bbd-c2c6-5271-96e7-009a87ff44bf}.png",

            "name" : "Windows PowerShell",

            "padding" : "0, 0, 0, 0",

            "snapOnInput" : true,

            "startingDirectory" : "%USERPROFILE%",

            "useAcrylic" : true

如您所見,字型、背景色彩、歷史記錄、大小和起始目錄全都是可以變更的。而且還能新增背景圖片。

摘要

全新 Windows Terminal 是 Windows 使用者期待已久的工具,即使目前還只是預覽版,對一般命令列使用者而言,這款工具已經展現了非常大的潛力。我相信,只要是經常使用命令列的使用者,不久之後就會紛紛將 Windows 作業系統的內建終端機改為 Windows Terminal。

Dan Franciscus

Dan Franciscus is a systems engineer and VMware Certified Professional (VCP) specializing in VMware, PowerShell, and other Microsoft-based technologies. You can reach Dan at his blog (http://www.winsysblog.com/) or Twitter at @dan_franciscus.

評語

Comments are disabled in preview mode.
主題

Sitefinity Training and Certification Now Available.

Let our experts teach you how to use Sitefinity's best-in-class features to deliver compelling digital experiences.

Learn More
Latest Stories
in Your Inbox

Subscribe to get all the news, info and tutorials you need to build better business apps and sites