@@ -3,7 +3,7 @@ | |||||
## debug | ## debug | ||||
# set -x | # set -x | ||||
. ~/.noaa.conf | |||||
. "$HOME/.noaa.conf" | |||||
declare -A levels=([DEBUG]=0 [INFO]=1 [WARN]=2 [ERROR]=3) | declare -A levels=([DEBUG]=0 [INFO]=1 [WARN]=2 [ERROR]=3) | ||||
log_level=${LOG_LEVEL} | log_level=${LOG_LEVEL} | ||||
@@ -1,7 +1,8 @@ | |||||
#!/bin/bash | #!/bin/bash | ||||
## import common lib | ## import common lib | ||||
. ~/common.sh | |||||
. "$HOME/.noaa.conf" | |||||
. "$NOAA_HOME/common.sh" | |||||
find "${NOAA_HOME}/map/" -type f -name '*.png' -mtime +1 -exec rm -f {} \; | find "${NOAA_HOME}/map/" -type f -name '*.png' -mtime +1 -exec rm -f {} \; | ||||
log "${NOAA_HOME}/map/ folder pruned" "INFO" | log "${NOAA_HOME}/map/ folder pruned" "INFO" | ||||
@@ -1,8 +1,8 @@ | |||||
#!/bin/bash | #!/bin/bash | ||||
## import common lib | ## import common lib | ||||
. ~/.noaa.conf | |||||
. "${NOAA_HOME}"/common.sh | |||||
. "$HOME/.noaa.conf" | |||||
. "$NOAA_HOME/common.sh" | |||||
wget -qr http://www.celestrak.com/NORAD/elements/weather.txt -O "${NOAA_HOME}"/predict/weather.txt | wget -qr http://www.celestrak.com/NORAD/elements/weather.txt -O "${NOAA_HOME}"/predict/weather.txt | ||||
wget -qr http://www.celestrak.com/NORAD/elements/amateur.txt -O "${NOAA_HOME}"/predict/amateur.txt | wget -qr http://www.celestrak.com/NORAD/elements/amateur.txt -O "${NOAA_HOME}"/predict/amateur.txt | ||||
@@ -1,8 +1,8 @@ | |||||
#!/bin/bash | #!/bin/bash | ||||
## import common lib | ## import common lib | ||||
. ~/.noaa.conf | |||||
. "${NOAA_HOME}"/common.sh | |||||
. "$HOME/.noaa.conf" | |||||
. "$NOAA_HOME/common.sh" | |||||
PREDICTION_START=$(/usr/bin/predict -t "${NOAA_HOME}"/predict/weather.tle -p "${1}" | head -1) | PREDICTION_START=$(/usr/bin/predict -t "${NOAA_HOME}"/predict/weather.tle -p "${1}" | head -1) | ||||
PREDICTION_END=$(/usr/bin/predict -t "${NOAA_HOME}"/predict/weather.tle -p "${1}" | tail -1) | PREDICTION_END=$(/usr/bin/predict -t "${NOAA_HOME}"/predict/weather.tle -p "${1}" | tail -1) | ||||
@@ -1,8 +1,8 @@ | |||||
#!/bin/bash | #!/bin/bash | ||||
## import common lib | ## import common lib | ||||
. ~/.noaa.conf | |||||
. "${NOAA_HOME}"/common.sh | |||||
. "$HOME/.noaa.conf" | |||||
. "$NOAA_HOME/common.sh" | |||||
# $1 = Satellite Name | # $1 = Satellite Name | ||||
# $2 = Frequency | # $2 = Frequency | ||||