power menu, redshift, polybar
This commit is contained in:
15
.config/polybar/scripts/info-hexdate/README.md
Normal file
15
.config/polybar/scripts/info-hexdate/README.md
Normal file
@@ -0,0 +1,15 @@
|
||||
# Script: info-hexdate
|
||||
|
||||
Print the current date in a hex format.
|
||||
|
||||

|
||||
|
||||
|
||||
## Module
|
||||
|
||||
```ini
|
||||
[module/info-hexdate]
|
||||
type = custom/script
|
||||
exec = ~/polybar-scripts/info-hexdate.sh
|
||||
interval = 60
|
||||
```
|
||||
11
.config/polybar/scripts/info-hexdate/info-hexdate.sh
Normal file
11
.config/polybar/scripts/info-hexdate/info-hexdate.sh
Normal file
@@ -0,0 +1,11 @@
|
||||
#!/bin/sh
|
||||
|
||||
day=$(timedatectl | grep "Local" | cut -d ":" -f2 | cut -d " " -f3 | cut -d "-" -f3)
|
||||
month=$(timedatectl | grep "Local" | cut -d ":" -f2 | cut -d " " -f3 | cut -d "-" -f2)
|
||||
year=$(timedatectl | grep "Local" | cut -d ":" -f2 | cut -d " " -f3 | cut -d "-" -f1)
|
||||
|
||||
day=$(echo "obase=16; $day" | bc)
|
||||
month=$(echo "obase=16; $month" | bc)
|
||||
year=$(echo "obase=16; $year" | bc)
|
||||
|
||||
echo "$day-$month-$year"
|
||||
BIN
.config/polybar/scripts/info-hexdate/screenshots/1.png
Normal file
BIN
.config/polybar/scripts/info-hexdate/screenshots/1.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.1 KiB |
Reference in New Issue
Block a user