oh-my-posh README

The project's README from github.com/JanDeDobbeleer/oh-my-posh. As one markdown file: README.md.

Oh My Posh logo – Prompt theme engine for any shell

MIT license badge

Build Status badge

Release version number badge

Documentation link badge ohmyposh.dev

Number of GitHub Downloads badge

This repo was made with love using GitKraken.

GitKraken shield

Sponsors

CodeRabbit

Want to become a sponsor?

Join the community

Mastodon badge

Discord badge

What started as the offspring of oh-my-posh2 for PowerShell resulted in a cross platform, highly customizable and extensible prompt theme engine. After 4 years of working on oh-my-posh, a modern and more efficient tool was needed to suit my personal needs.

:heart: Support :heart:

Swag - Show your love with a t-shirt!

GitHub - One time support, or a recurring donation?

Ko-Fi - No coffee, no code.

Features

Documentation

Documentation

Reviews

Thanks

oh-my-posh (JanDeDobbeleer/oh-my-posh)

Searching Database…

这是什么?oh-my-posh 是一个跨平台的命令行提示符主题引擎:它负责渲染你在终端里看到的那行提示符,并且高度可定制、可扩展。
它会替换我的 shell,还是运行在我现有的 shell 里面?它不替换任何东西——你的 shell 保持原样,oh-my-posh 只负责绘制提示符。该项目自称与 shell 和平台无关。
我怎么安装它,并把提示符切换成它?它是一个单独的 Go 二进制文件:按照 ohmyposh.dev 上的指南为你的操作系统安装,然后让 shell 配置指向 oh-my-posh,由它来渲染你的提示符,再挑一个主题。
它能在哪些 shell 里使用?大部分都行:支持 bash、zsh、fish、PowerShell、cmd 和 nushell,并且可以在 Windows、macOS 和 Linux 上运行。
主题里的图标能直接显示吗,还是需要特殊字体?这些主题依赖 Nerd Fonts——一种打了补丁、附带额外图标字形的字体(仓库带有 nerd-fonts 标签)——所以要在终端里安装一款,图标才能正常显示。
作者为什么不继续维护 oh-my-posh2,而是重写了它?oh-my-posh 最初是 oh-my-posh2 的 PowerShell 版衍生项目。在做了 4 年之后,作者需要一个更现代、更高效的工具来满足自己的需求——这就是现在这个仓库里的跨平台引擎。
right prompt、transient prompt 和 secondary prompt 到底是干什么的?它们都是额外的提示符形式:right prompt 把信息显示在终端右侧,secondary prompt 会增加第二条提示符行,transient prompt 则让你已经输入过的行收起为更短的形式——既保留上下文,又不会弄乱当前的活动行。
它能在提示符里显示 git 信息吗?可以——git 是它的招牌集成之一,也是项目的核心主题:当你在文件系统里移动时,提示符可以反映你当前所在的仓库。
Size
115.8 MB
Stars
23.6K
Age
7y
Commits · 90 Days