Skip to content

Instantly share code, notes, and snippets.

@mayannaoliveira
Created July 18, 2025 01:07
Show Gist options
  • Select an option

  • Save mayannaoliveira/463dcbf8e3ebfd56f2cba7bd98430ffe to your computer and use it in GitHub Desktop.

Select an option

Save mayannaoliveira/463dcbf8e3ebfd56f2cba7bd98430ffe to your computer and use it in GitHub Desktop.
My OhMyPosh theme inspirated in 1_shell.omp.json
// Oh My Posh https://ohmyposh.dev/
// Theme inspirated in https://github.com/JanDeDobbeleer/oh-my-posh/blob/main/themes/1_shell.omp.json
{
"$schema": "https://raw.githubusercontent.com/JanDeDobbeleer/oh-my-posh/main/themes/schema.json",
"blocks": [
{
"alignment": "left",
"segments": [
// Shell https://ohmyposh.dev/docs/segments/system/shell
{
"type": "shell",
"style": "plain",
"foreground": "#fb01c7",
"template": " \ue86c {{ .Name }} ",
"properties": {
"mapped_shell_names": {
"pwsh": "PS"
}
}
},
// Session https://ohmyposh.dev/docs/segments/system/session#properties
{
"foreground": "#45F1C2",
"style": "plain",
"template": "\ue70f {{ .UserName }} on",
"type": "session"
},
// Path https://ohmyposh.dev/docs/segments/system/path
{
"foreground": "#0CA0D8",
"properties": {
"folder_separator_icon": "/",
"style": "full"
},
"style": "plain",
"template": " \uf07b {{ .Path }} ",
"type": "path"
},
// Git
{
"foreground": "#af3dff",
"properties": {
"fetch_stash_count": true,
"fetch_upstream_icon": true
},
"style": "plain",
"template": "{{ .UpstreamIcon }}{{ .HEAD }}{{ if gt .StashCount 0 }} \ueb4b {{ .StashCount }}{{ end }} ",
"type": "git"
},
// Subversion https://ohmyposh.dev/docs/segments/scm/svn
{
"type": "svn",
"style": "plain",
"foreground": "#d30019",
"template": " \ue0a0{{.Branch}} r{{.BaseRev}} {{.Working.String}} ",
"properties": {
"fetch_status": true
}
},
// Jujutsu https://ohmyposh.dev/docs/segments/scm/jujutsu
{
"type": "jujutsu",
"style": "powerline",
"foreground": "#e3e50a",
"template": "\udb85\uddc6 {{.ChangeID}}{{if .Working.Changed}} \uf044 {{ .Working.String }}{{ end }} ",
"properties": {
"fetch_status": true,
"ignore_working_copy": false
}
}
],
"type": "prompt"
},
{
"alignment": "left",
"newline": true,
"segments": [
// Battery https://ohmyposh.dev/docs/segments/system/battery
{
"type": "battery",
"style": "plain",
"foreground_templates": [
"{{if eq \"Charging\" .State.String}}#40c4ff{{end}}",
"{{if eq \"Discharging\" .State.String}}#ff5722{{end}}",
"{{if eq \"Full\" .State.String}}#4caf50{{end}}"
],
"template": " {{ if not .Error }}{{ .Icon }}{{ .Percentage }}{{ end }} ",
"properties": {
"discharging_icon": "\udb81\udea6 ",
"charging_icon": "\udb80\udc7c ",
"charged_icon": "\uf240 "
}
},
{
"foreground": "#f39c21",
"style": "plain",
"template": "\ue3bf ",
"type": "root"
},
// Connection https://ohmyposh.dev/docs/segments/system/connection
{
"type": "connection",
"style": "plain",
"foreground": "#001be9",
"template": "{{ if eq .Type \"wifi\"}}\uf1eb{{ else if eq .Type \"ethernet\"}}\ueba9{{ end }} "
},
// Time https://ohmyposh.dev/docs/segments/system/time
{
"type": "time",
"style": "plain",
"template": " \udb80\udcf0 {{ .CurrentDate | date .Format }} ",
"foreground": "#e7ff9f",
"properties": {
"time_format": "Monday \uf073 02-Jan-06 \udb82\udd54 15:04:05"
}
}
],
"type": "prompt"
},
{
"alignment": "left",
"newline": true,
"segments": [
// Deno https://ohmyposh.dev/docs/segments/cli/deno
{
"type": "deno",
"style": "plain",
"foreground": "#3C82F6",
"template": " \ue7c0 {{ if .Error }}{{ .Error }}{{ else }}{{ .Full }}{{ end }} "
},
// Bun https://ohmyposh.dev/docs/segments/cli/bun
{
"type": "bun",
"style": "plain",
"foreground": "#7af63c",
"template": " \ue76f {{ if .Error }}{{ .Error }}{{ else }}{{ .Full }}{{ end }} "
},
// PNPM https://ohmyposh.dev/docs/segments/cli/pnpm
{
"type": "pnpm",
"style": "plain",
"foreground": "#ebff12",
"template": " \uDB80\uDEC1 {{.Full}} "
},
// Yarn https://ohmyposh.dev/docs/segments/cli/yarn
{
"type": "yarn",
"style": "plain",
"foreground": "#8432ff",
"template": " \ue6a7 {{.Full}} "
},
// NPM https://ohmyposh.dev/docs/segments/cli/npm
{
"type": "npm",
"style": "plain",
"foreground": "#60ff6f",
"template": "\ue5fa {{ .Full }} "
},
// Docker https://ohmyposh.dev/docs/segments/cli/docker
{
"type": "docker",
"style": "plain",
"foreground": "#00fbff",
"template": " \uf308 {{ .Context }} "
},
// Python https://ohmyposh.dev/docs/segments/languages/python
{
"type": "python",
"style": "plain",
"foreground": "#e8fd00",
"template": " \ue73c {{ if .Error }}{{ .Error }}{{ else }}{{ if .Venv }}{{ .Venv }} {{ end }}{{ .Full }}{{ end }} "
},
// Lua https://ohmyposh.dev/docs/segments/languages/lua
{
"type": "lua",
"style": "plain",
"foreground": "#6d50ff",
"template": " \ue826 {{ if .Error }}{{ .Error }}{{ else }}{{ .Full }}{{ end }} "
}
],
"type": "prompt"
},
{
"alignment": "left",
"newline": true,
"segments": [
//Upgrade notice https://ohmyposh.dev/docs/segments/system/upgrade
{
"type": "upgrade",
"style": "plain",
"foreground": "#ffd500",
"properties": {
"cache_duration": "168h"
}
},
// Status Code https://ohmyposh.dev/docs/segments/system/status
{
"type": "status",
"style": "plain",
"foreground": "#ff0000",
"background_templates": [
"{{ if .Error }} {{ end }}"
],
"template": " {{ if eq .Code 0 }}\uf00c{{ else }}\uf071 {{ reason .Code }}{{ end }} ",
"properties": {
"always_enabled": true
}
},
// General https://ohmyposh.dev/docs/configuration/general
{
"foreground": "#bbbbbb",
"style": "plain",
"template": " \udb81\ude8c ",
"type": "text"
}
],
"type": "prompt"
}
],
"version": 3
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment