Last active
September 17, 2021 12:07
-
-
Save GiampaoloGabba/d4315d3395c560ba496a1a15409a1e7e to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
echo "Inserisci il nome host che comparirà nella barra degli indirizzi:" | |
read -p "Host: " HOST | |
sudo wget https://github.com/JanDeDobbeleer/oh-my-posh/releases/latest/download/posh-linux-amd64 -O /usr/local/bin/oh-my-posh | |
sudo chmod +x /usr/local/bin/oh-my-posh | |
mkdir ~/.poshthemes | |
cd ~/.poshthemes | |
wget https://gist.githubusercontent.com/GiampaoloGabba/b3a0acbda32e8acd7cb5488ef21c1de7/raw/9c469d6ca912f75ea61fc90888ec5e1f897313fc/oh-my-posh.omp.json | |
sed -i "s/{{if .Root}}/$HOST | {{if .Root}}/g" ~/.poshthemes/oh-my-posh.omp.json | |
eval "$(oh-my-posh --init --shell bash --config ~/.poshthemes/oh-my-posh.omp.json)" | |
echo 'eval "$(oh-my-posh --init --shell bash --config ~/.poshthemes/oh-my-posh.omp.json)"' >> ~/.bashrc |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment