docs(macos): add MacPorts install instructions

https://ports.macports.org/port/oh-my-posh/
This commit is contained in:
Herby Gillot 2024-05-25 15:51:10 -04:00 committed by Jan De Dobbeleer
parent 099f6cb6c3
commit 9cbacddddf
3 changed files with 46 additions and 11 deletions

View file

@ -1,11 +1,5 @@
A [Homebrew][brew] Formula and Cask (macOS only) are available for easy installation.
:::warning Linux
When installing Homebrew for Linux,
be sure to follow *[Next steps][nextsteps]* instructions to add Homebrew to your PATH and to your
bash shell profile script, and *[Requirements][requirements]* to build Oh My Posh.
:::
```bash
brew install jandedobbeleer/oh-my-posh/oh-my-posh
```
@ -18,7 +12,7 @@ This installs two things:
If you want to use a predefined theme, you can find them in `$(brew --prefix oh-my-posh)/themes`, referencing them as such
will always keep them compatible when updating Oh My Posh.
## Update
## Updating
```bash
brew update && brew upgrade oh-my-posh
@ -34,7 +28,5 @@ brew update && brew upgrade && exec zsh
:::
[brew]: https://brew.sh
[requirements]: https://docs.brew.sh/Homebrew-on-Linux#requirements
[nextsteps]: https://docs.brew.sh/Homebrew-on-Linux#install
[themes]: https://ohmyposh.dev/docs/themes
[strange]: https://github.com/JanDeDobbeleer/oh-my-posh/issues/1287

View file

@ -51,6 +51,12 @@ curl -s https://ohmyposh.dev/install.sh | bash -s -- -d ~/bin
</TabItem>
<TabItem value="homebrew">
:::warning
When installing Homebrew for Linux,
be sure to follow *[Next steps][nextsteps]* instructions to add Homebrew to your PATH and to your
bash shell profile script, and *[Requirements][requirements]* to build Oh My Posh.
:::
<InstallHomebrew />
</TabItem>
@ -58,4 +64,6 @@ curl -s https://ohmyposh.dev/install.sh | bash -s -- -d ~/bin
<Next />
[fonts]: /docs/installation/fonts
[requirements]: https://docs.brew.sh/Homebrew-on-Linux#requirements
[nextsteps]: https://docs.brew.sh/Homebrew-on-Linux#install
[fonts]: /docs/installation/fonts

View file

@ -18,12 +18,47 @@ As the standard terminal only supports [256 colors][256-colors], we advise using
To display all icons, we recommend the use of a [Nerd Font][fonts].
:::
## Installation
<Tabs
defaultValue="homebrew"
groupId="install"
values={[
{ label: 'homebrew', value: 'homebrew', },
{ label: 'MacPorts', value: 'macports', }
]
}>
<TabItem value="homebrew">
<InstallHomebrew />
</TabItem>
<TabItem value="macports">
You can install Oh My Posh via [MacPorts] which is maintained by the [community].
```bash
sudo port selfupdate
sudo port install oh-my-posh
```
Oh My Posh will be installed at `/opt/local/bin/oh-my-posh`.
## Updating
```bash
sudo port selfupdate
sudo port upgrade oh-my-posh
```
More details on the [ports page] for Oh My Posh.
</TabItem>
</Tabs>
<Next />
[256-colors]: /docs/configuration/colors#standard-colors
[iterm2]: https://iterm2.com
[fonts]: /docs/installation/fonts
[MacPorts]: https://www.macports.org
[ports page]: https://ports.macports.org/port/oh-my-posh
[community]: https://ports.macports.org/port/oh-my-posh/