Logo Ricky
  • Home
  • About
  • More
    Skills Experiences Education Projects
  • Posts
  • Notes
  • Activities
  • Transform
  • English
    English Chinese
  • Dark Theme
    Light Theme Dark Theme System Theme
Logo Inverted Logo
  • Tags
  • A10
  • ACME
  • AD
  • AES
  • AI
  • Aliyun
  • Ansible
  • APP
  • Application Delivery Controller
  • Arceus
  • Argo CD
  • ASCII
  • Authentication
  • Authorization
  • AWS
  • BASH
  • Bayonet
  • Benchmark
  • BGP
  • BIRD
  • Board Game
  • Browser
  • Byte
  • Cache
  • CDN
  • Channel
  • Chart
  • Checklist
  • Chrome
  • Chrome OS
  • Chrony
  • CI
  • Cilium
  • Cisco
  • Cloud-Native
  • Cloudflare
  • Cluster
  • Command Line
  • Completion
  • Config
  • Container
  • CPU
  • CURL
  • Data
  • Database
  • Debug
  • Dehydrated
  • Design
  • DevSecOps
  • Diagrams
  • Dmg
  • DNS
  • DNS-01
  • Docker
  • EFF
  • ElasticSearch
  • ELK
  • Emoji
  • EMQX
  • Encode
  • Encrypt
  • ESXi
  • Extension
  • Firewall
  • Fortigate
  • Fortinet
  • FortiOS
  • Game
  • GeoIP
  • GIN
  • Git
  • GitBook
  • Github
  • Gitlab
  • GitOps
  • Gluetun
  • Go
  • Go-Mysql-Elasticsearch
  • Golang
  • Google
  • GPG
  • GraphQL
  • HA
  • HAProxy
  • Hash
  • HomeLab
  • Htop
  • HTTP
  • Infra
  • Infrastructure
  • Input Method
  • Interview
  • Introduction
  • IPhone
  • Iptables
  • Iso
  • Issue
  • ITerm2
  • Jenkins
  • Jsoniter
  • Juniper
  • JWT
  • Kibana
  • Kubernetes
  • LDAP
  • Leetcode
  • Lightweight
  • Linkerd
  • Linux
  • LLM
  • Log
  • Lua
  • Lullaby
  • LVM
  • Machinelearning
  • MacOS
  • Markdown
  • Mattermost
  • Mermaid
  • MinIO
  • Module
  • MQTT
  • MSS
  • MTU
  • Music
  • MyDumper
  • MySQL
  • NAS
  • Netcat
  • Network
  • Nftables
  • Nginx
  • OAuth
  • OIDC
  • Ollama
  • OpenResty
  • Parquet
  • Percona
  • Pinyin
  • Pip
  • Plugin
  • Pokemon
  • PowerDNS
  • PowerShell
  • Pprof
  • Principle
  • Prometheus
  • Protobuf
  • Proxy
  • Push
  • Python
  • QRCode
  • R
  • RAID
  • RDP
  • Redis
  • Regex
  • Ringtone
  • Route
  • Rust
  • S3
  • ScreenShot
  • Security
  • Selenium
  • Sentry
  • Service Mesh
  • SFTP
  • SHELL
  • Slides
  • Snow
  • Software
  • SonarQube
  • SQL
  • SSH
  • SSL
  • String
  • Switch
  • Sync
  • Synology
  • System
  • Tcpdump
  • Telegram
  • Terminal
  • Terraform
  • Test
  • Testing
  • Time
  • Timeout
  • TLS
  • Tor
  • Trace
  • Traefik
  • Travel
  • Tunnel
  • Typora
  • Ubuntu
  • URL
  • UserAgent
  • V2Ray
  • Vagrant
  • Video
  • Vim
  • Virtualization
  • Visualization
  • VNC
  • VPN
  • VSCode
  • WAF
  • Web
  • WebAssembly
  • Webp
  • Windows
  • WSL
  • YAML
  • Youtube
  • Zabbix
  • Zero Trust
  • Zim
  • ZSH
  • 台語
Hero Image
使用 oh-my-posh 美化 PowerShell 樣式

使用 oh-my-posh 美化 PowerShell 樣式 # 這會從 PowerShell Gallery 下載並安裝 posh-git 和 oh-my-posh 這兩個模組,前者是在命令列中顯示 Git 專案的相關資訊,後者則是美美的樣式套件 Install-Module posh-git -Scope CurrentUser Install-Module oh-my-posh -Scope CurrentUser # 接著我們要修改 PowerShell 啟動時所載入的設定檔,在 PowerShell 中輸入 $PROFILE 可得到當前使用者啟動 PowerShell 時,會載入的個人設定檔位置。 # 你的電腦可能沒有這個實體檔案,這時可以執行下面的指令,如果沒有該設定檔,則建立一個,然後使用 notepad 來開啟該設定檔。 if (!(Test-Path -Path $PROFILE )) { New-Item -Type File -Path $PROFILE -Force } notepad $PROFILE 最後在該設定檔中加入下列指令 Import-Module posh-git Import-Module oh-my-posh Set-Theme Paradox oh-my-posh 內建了很多樣式,你也可以使用 Get-Theme 這個 Cmdlet 指令取得 oh-my-posh 有提供的所有樣式及相關檔案位置

Thursday, December 10, 2020 Read
Navigation
  • About
  • Skills
  • Experiences
  • Education
  • Projects
Contact me:
  • zeyanlin@outlook.com
  • linzeyan
  • Ricky
  • Ricky