blob: 7d43ccea0f09ff64022cb683dbc82c70f6b9a23e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
#!/bin/bash
# Other icons that could be used:
# Git:
# Config:
# Dotfiles tracker for dwmblocks (using yadm)
# This block aims to never show up (to be out of sight, out of mind)
# If the following situation occurs, the following icons will be shown:
#
# - : There are uncommitted changes
# - : There are staged changes
# - : Unpushed changes
# - : Upstream has changes that are not pulled
#
# These icons will sit next the this block's base icon
#
# Only one icon will be shown at a time, and the order of priority is:
# uncommitted > staged > unpushed > upstream
status=$(yadm status --porcelain 2>/dev/null)
[ -z "$status" ] && exit 0
printf '{"text": "", "class":"block"}\n'
|