Dough Git

clove/clockworkDots

omp/config.toml

back to omp

# omp/config.toml

console_title_template = '{{ .Shell }} in {{ .Folder }}'
version = 3
final_space = true

# Clockwork palette, matches ~/.config/sway/clockwork
[palette]
  bg = '#050A14'
  fg = '#E9E4DF'
  glow = '#5FD4F0'
  frost = '#9EE8F8'
  blue = '#4A8FE0'
  sky = '#6AA6E8'
  crimson = '#C8283E'
  scarlet = '#E0485C'
  rose = '#D7718F'
  gold = '#D4B072'
  yellow = '#EBCB6B'
  peach = '#F2C29C'
  jade = '#5CC8A0'
  mint = '#86DDBC'
  grey = '#4A5A72'

[secondary_prompt]
  template = '❯❯ '
  foreground = 'p:blue'
  background = 'transparent'

[transient_prompt]
  template = '❯ '
  background = 'transparent'
  foreground_templates = [
    '{{ if gt .Code 0 }}p:scarlet{{ end }}',
    '{{ if eq .Code 0 }}p:glow{{ end }}',
  ]

[[blocks]]
  type = 'prompt'
  alignment = 'left'
  newline = true

  # user@host
  [[blocks.segments]]
    type = 'session'
    style = 'powerline'
    powerline_symbol = ''
    template = ' {{ if .Root }}⚡ {{ end }}{{ .UserName }}@{{ .HostName }} '
    foreground = 'p:bg'
    background = 'p:glow'

    [blocks.segments.properties]
      cache_duration = 'none'

  # Working directory
  [[blocks.segments]]
    type = 'path'
    style = 'powerline'
    powerline_symbol = ''
    template = ' {{ .Path }} '
    foreground = 'p:bg'
    background = 'p:sky'

    [blocks.segments.properties]
      cache_duration = 'none'
      style = 'full'
      home_icon = '~'
      folder_separator_icon = '/'

  # Git branch, dirty flag, ahead/behind counts
  [[blocks.segments]]
    type = 'git'
    style = 'powerline'
    powerline_symbol = ''
    template = ' {{ .HEAD }}{{ if or (.Working.Changed) (.Staging.Changed) }}*{{ end }}{{ if gt .Behind 0 }} ⇣{{ .Behind }}{{ end }}{{ if gt .Ahead 0 }} ⇡{{ .Ahead }}{{ end }} '
    foreground = 'p:bg'
    background = 'p:jade'
    background_templates = [
      '{{ if or (.Working.Changed) (.Staging.Changed) }}p:gold{{ end }}',
      '{{ if gt .Behind 0 }}p:frost{{ end }}',
      '{{ if gt .Ahead 0 }}p:frost{{ end }}',
    ]

    [blocks.segments.properties]
      cache_duration = 'none'
      branch_icon = ' '
      commit_icon = '@'
      fetch_status = true
      fetch_upstream_icon = true

  # Python, only inside Python projects
  [[blocks.segments]]
    type = 'python'
    style = 'powerline'
    powerline_symbol = ''
    template = '  {{ if .Venv }}{{ .Venv }}{{ else }}{{ .Full }}{{ end }} '
    foreground = 'p:bg'
    background = 'p:yellow'

    [blocks.segments.properties]
      cache_duration = 'none'
      display_mode = 'files'
      fetch_virtual_env = true

  # Node, only inside Node projects
  [[blocks.segments]]
    type = 'node'
    style = 'powerline'
    powerline_symbol = ''
    template = '  {{ .Full }} '
    foreground = 'p:bg'
    background = 'p:mint'

    [blocks.segments.properties]
      cache_duration = 'none'
      display_mode = 'files'
      fetch_package_manager = false

  # Command duration, shown past 5s
  [[blocks.segments]]
    type = 'executiontime'
    style = 'powerline'
    powerline_symbol = ''
    template = '  {{ .FormattedMs }} '
    foreground = 'p:bg'
    background = 'p:peach'

    [blocks.segments.properties]
      cache_duration = 'none'
      threshold = 5000
      style = 'austin'

  # Exit code, shown only on failure
  [[blocks.segments]]
    type = 'status'
    style = 'powerline'
    powerline_symbol = ''
    template = '  {{ .Code }} '
    foreground = 'p:fg'
    background = 'p:crimson'

    [blocks.segments.properties]
      cache_duration = 'none'
      always_enabled = false

[[blocks]]
  type = 'prompt'
  alignment = 'left'
  newline = true

  [[blocks.segments]]
    type = 'text'
    style = 'plain'
    template = '❯'
    background = 'transparent'
    foreground_templates = [
      '{{ if gt .Code 0 }}p:scarlet{{ end }}',
      '{{ if eq .Code 0 }}p:glow{{ end }}',
    ]

    [blocks.segments.properties]
      cache_duration = 'none'