Use libsecret to hide API key

This commit is contained in:
LordMathis 2018-06-12 15:10:25 +02:00
parent 15c2f3964e
commit 10abac3a82
2 changed files with 7 additions and 1 deletions

View File

@ -24,7 +24,7 @@ get_icon() {
echo $icon
}
KEY=""
KEY=`secret-tool lookup openweathermap api_key`
CITY=""
UNITS="metric"
SYMBOL="°"

6
bin/setup.sh Executable file
View File

@ -0,0 +1,6 @@
#!/bin/sh
echo "Enter OpenWeatherMap API key"
read line
echo $line | secret-tool store --label='OpenWeatherMap API Key' openweathermap api_key
secret-tool lookup openweathermap api_key