[clock.py] Add actions to open khal and tty-clock
This commit is contained in:
parent
a643ae78ae
commit
cb9bc04f25
1 changed files with 16 additions and 10 deletions
|
@ -50,24 +50,30 @@ try:
|
|||
|
||||
localcolor = color_for(localnow)
|
||||
|
||||
khal_link = lambda x: "%{A1:i3-sensible-terminal -e khal interactive &:}" + x + "%{A}"
|
||||
clock_link = lambda x, args: "%{A1:i3-sensible-terminal -e tty-clock -cC3 " + args + " &:}" + x + "%{A}"
|
||||
|
||||
print(
|
||||
localcolor +
|
||||
localnow.strftime("%A") +
|
||||
"%{F} " +
|
||||
khal_link(
|
||||
localcolor +
|
||||
localnow.strftime("%A") +
|
||||
"%{F} "
|
||||
) +
|
||||
|
||||
# face_for(leftnow) +
|
||||
|
||||
" %{T4}" + localcolor + localnow.strftime("%H") + "%{F}"
|
||||
clock_link(" %{T4}" + localcolor + localnow.strftime("%H") + "%{F}", "") +
|
||||
"%{O2}%{T8}" + face_for(localnow) +
|
||||
"%{O2}%{T4}" + localcolor + localnow.strftime("%M") + "%{T-}%{F}" +
|
||||
" " +
|
||||
clock_link("%{O2}%{T4}" + localcolor + localnow.strftime("%M") + "%{T-}%{F} ", "-s") +
|
||||
|
||||
# face_for(rightnow) + " " +
|
||||
|
||||
" " +
|
||||
localcolor +
|
||||
localnow.strftime("%d %b") +
|
||||
"%{F}",
|
||||
khal_link(
|
||||
" " +
|
||||
localcolor +
|
||||
localnow.strftime("%d %b") +
|
||||
"%{F}"
|
||||
),
|
||||
|
||||
flush = True
|
||||
)
|
||||
|
|
Loading…
Reference in a new issue