power menu, redshift, polybar

This commit is contained in:
azpsen
2024-01-28 16:37:10 -06:00
parent 89516a6ce1
commit 319b44ecbd
307 changed files with 7642 additions and 5 deletions

View File

@@ -0,0 +1,18 @@
# Script: info-ethermine
This script reports the current hashrate (in MH/s) for your ethermine account.
## Dependencies
* `python-requests`
## Module
```ini
[module/info-ethermine]
type = custom/script
exec = ~/polybar-scripts/info-ethermine.sh
interval = 60
```

View File

@@ -0,0 +1,12 @@
#!/usr/bin/env python3
import requests
miner = ""
data = requests.get(f"https://api.ethermine.org/miner/{miner}/dashboard").json()['data']['statistics']
data = data[-1]
current_hash_rate = data["currentHashrate"]
currentMHs = round(current_hash_rate/1e6, 1)
print(f"{currentMHs}MH/s")