dotfiles/dot_local/bin/executable_updateOhMyPosh
2024-09-29 20:36:15 +02:00

9 lines
315 B
Bash

#!/bin/bash
newestVersion="$(curl -sL https://api.github.com/repos/JanDeDobbeleer/oh-my-posh/releases/latest | jq -r '.name')"
localVersion="v$(oh-my-posh --version)"
tmpFile="$(mktemp -u)"
test "$newestVersion" != "$localVersion" && {
curl -so "$tmpFile" https://ohmyposh.dev/install.sh
bash "$tmpFile"
}