31 lines
932 B
Bash
Executable File
31 lines
932 B
Bash
Executable File
#!/bin/sh
|
|
|
|
if [ -f /usr/bin/rsstail ];then
|
|
|
|
feed="https://github.com/void-linux/void-packages/commits/master.atom"
|
|
updatedpkgs="$(rsstail -1 -u ${feed} | grep -e "Update" -e "update" | wc -l)"
|
|
newpkgs="$(rsstail -1 -u ${feed} | grep -e "New" -e "new" | wc -l)"
|
|
sysupdates="$(xbps-install -nuM | wc -l)"
|
|
#sysupdates="$(xbps-install -Snu | wc -l)"
|
|
|
|
notify-send --urgency=critical """CAMBIOS EN EL REPOSITORIO:
|
|
Paquetes actualizados: ${updatedpkgs}
|
|
Nuevos paquetes: ${newpkgs}
|
|
|
|
ACTUALIZACIONES DE SISTEMA:
|
|
Disponible actualmente: ${sysupdates}"""
|
|
|
|
echo """CAMBIOS EN EL REPOSITORIO:
|
|
Paquetes actualizados: ${updatedpkgs}
|
|
Nuevos paquetes: ${newpkgs}
|
|
|
|
ACTUALIZACIONES DE SISTEMA:
|
|
Disponible actualmente: ${sysupdates}"""
|
|
elif [ ! -f /usr/bin/rsstail ];then
|
|
echo "[ERROR] Este script requiere del paquete: 'rsstail'"
|
|
exit 0;
|
|
else
|
|
echo "Algo salió mal al verificar: /usr/bin/rsstail"
|
|
exit 0;
|
|
fi
|