mirror of
https://github.com/xsghetti/HyprCrux.git
synced 2025-07-02 21:30:39 -04:00
hyprland updates
This commit is contained in:
parent
a379eebea0
commit
e23ba45888
7 changed files with 64 additions and 22 deletions
30
.config/hypr/scripts/time_in_binary.py
Normal file
30
.config/hypr/scripts/time_in_binary.py
Normal file
|
@ -0,0 +1,30 @@
|
|||
#!/bin/python3
|
||||
|
||||
import datetime
|
||||
import sys
|
||||
|
||||
|
||||
def hours_in_binary(hours):
|
||||
hours = bin(hours)[2:]
|
||||
if len(hours) < 4:
|
||||
hours = "0" * (4 - len(hours)) + hours
|
||||
return hours.replace("1", "●").replace("0", "○")
|
||||
|
||||
|
||||
def minutes_in_binary(minutes):
|
||||
minutes = bin(minutes)[2:]
|
||||
if len(minutes) < 6:
|
||||
minutes = "0" * (6 - len(minutes)) + minutes
|
||||
return minutes.replace("1", "●").replace("0", "○")
|
||||
|
||||
|
||||
def seconds_in_binary(seconds):
|
||||
return minutes_in_binary(seconds)
|
||||
|
||||
|
||||
t = datetime.datetime.now()
|
||||
fun = [hours_in_binary, minutes_in_binary, seconds_in_binary]
|
||||
time = [t.hour, t.minute, t.second]
|
||||
if __name__ == "__main__":
|
||||
args = int(sys.argv[1])
|
||||
print(fun[args](time[args]))
|
Loading…
Add table
Add a link
Reference in a new issue