mirror of
https://github.com/olexsmir/dotfiles.git
synced 2026-01-15 16:51:34 +02:00
Add alt+f4 to sxhkd, update polybar scripts
This commit is contained in:
parent
351fd863ac
commit
946566abc6
8 changed files with 27 additions and 22 deletions
|
|
@ -1,13 +1,9 @@
|
|||
#!/bin/sh
|
||||
#!/usr/bin/env bash
|
||||
if ! updates_arch=$(checkupdates 2> /dev/null | wc -l ); then
|
||||
updates_arch=0
|
||||
fi
|
||||
|
||||
if ! updates_aur=$(yay -Qum 2> /dev/null | wc -l); then
|
||||
# if ! updates_aur=$(cower -u 2> /dev/null | wc -l); then
|
||||
# if ! updates_aur=$(trizen -Su --aur --quiet | wc -l); then
|
||||
# if ! updates_aur=$(pikaur -Qua 2> /dev/null | wc -l); then
|
||||
# if ! updates_aur=$(rua upgrade --printonly 2> /dev/null | wc -l); then
|
||||
updates_aur=0
|
||||
fi
|
||||
|
||||
|
|
|
|||
|
|
@ -1,8 +1,11 @@
|
|||
import requests, os
|
||||
|
||||
API_KEY = os.getenv("OWM_POLYBAR")
|
||||
CITY = os.getenv("OWM_CITY")
|
||||
try:
|
||||
JSON = requests.get(f"http://api.openweathermap.org/data/2.5/weather?q={CITY}&lang=EN&&units=metric&appid={API_KEY}").json()
|
||||
JSON = requests.get(
|
||||
f"http://api.openweathermap.org/data/2.5/weather?q={CITY}&lang=EN&&units=metric&appid={API_KEY}"
|
||||
).json()
|
||||
print("", int(JSON["main"]["temp"]), "°С")
|
||||
except Exception as e:
|
||||
print(" err")
|
||||
|
|
|
|||
|
|
@ -1,2 +1,5 @@
|
|||
#!/bin/sh
|
||||
cat /proc/net/wireless | grep "wlp3s0" | awk '{print $4}' | grep -o '[0-9]*'
|
||||
cat /proc/net/wireless \
|
||||
| grep "wlp3s0" \
|
||||
| awk '{print $4}' \
|
||||
| grep -o '[0-9]*'
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue