mirror of https://framagit.org/kyodev/kyopages.git
getInfo 2.1.0
This commit is contained in:
parent
8b5f80ef95
commit
5d02df89ab
175
scripts/getInfo
175
scripts/getInfo
|
@ -1,7 +1,7 @@
|
|||
#!/bin/bash
|
||||
|
||||
version=2.0.0
|
||||
date="09/10/2017"
|
||||
version=2.1.0
|
||||
date="10/10/2017"
|
||||
projet="simpledeb"
|
||||
contact="IRC freenode ##sdeb ou https://framagit.org/kyodev/kyopages/issues/"
|
||||
script="getInfo"
|
||||
|
@ -259,37 +259,40 @@ f__wget_test(){ # 08/10/2017
|
|||
exit 0
|
||||
}
|
||||
|
||||
f_help(){ # 06/10/2017
|
||||
f_help(){ # 10/10/2017
|
||||
printf "$BLUE"
|
||||
cat << 'EOF'
|
||||
----------------------------------------------------------------------
|
||||
./getInfo : exécution normale, rapport markdown configuration & diagnostic
|
||||
./getInfo : exécution normale, rapport markdown de la configuration
|
||||
getInfo : exécution normale si script installé dans le système
|
||||
|
||||
options:
|
||||
-d : (dmesg) {erreur & warning & critique} root requis, rapport markdown seul de dmesg
|
||||
-c : (catégorie) menu sélection catégorie d'analyse
|
||||
-h : (help) affichage aide
|
||||
-l : (list) afficher le rapport markdown existant
|
||||
-p : (paste) exporte le rapport markdown existant, durée du paste standard 7 jours
|
||||
--ip : affiche ip(s) publique(s) (ipv4 / ipv6), infos confidentielles, sans rapport markdown
|
||||
--mac : affiche les adresses Mac, infos confidentielles, sans rapport markdown
|
||||
--ssid : affiche configurations ssid, infos confidentielles, sans rapport markdown
|
||||
root et NetworkManager requis
|
||||
|
||||
--debug-paste : le résultat json du paste sera affiché après export
|
||||
-p : (paste) exporte le rapport markdown existant, durée standard du paste 7 jours
|
||||
-tn : durée du paste de n jour(s)
|
||||
|
||||
--dmesg : dmesg {erreur & warning & critique} et journaux Xorg, root requis, rapport markdown créé
|
||||
--ip : affiche ip(s) publique(s) (ipv4 / ipv6), infos confidentielles, pas de rapport markdown
|
||||
--mac : affiche les adresses Mac, infos confidentielles, pas de rapport markdown
|
||||
--ssid : affiche configurations ssid, infos confidentielles, pas de rapport markdown,
|
||||
root et NetworkManager requis
|
||||
|
||||
-i, --install : installation du script dans le système, droits root requis
|
||||
-r, --remove : suppression du script dans le système, droits root requis
|
||||
--debug-batt : rapport batterie avec affichage BAT?/uevent et rapport markdown
|
||||
--debug-paste : le résultat json du paste sera affiché après export
|
||||
|
||||
-i, --install : installation du script dans le système, root requis
|
||||
-r, --remove : suppression du script dans le système, root requis
|
||||
-u, --upgrade : upgrade script si maj possible
|
||||
-v, --version : version du script, en ligne et en cours d'exécution
|
||||
EOF
|
||||
echo -e "$STD\n plus d'infos: $GREEN$urlNotice\n"
|
||||
}
|
||||
|
||||
fi_batt(){ # 05/10/2017
|
||||
fi_batt(){ # 10/10/2017
|
||||
[ "$batt_nb" ] || figet_battery # appel figet_battery si pas déjà fait par fi_systeme
|
||||
[ "$batt_nb" ] || return 0
|
||||
[ "$batt_nb" -gt 0 ] || return 0
|
||||
text="## batterie(s) \n\n"
|
||||
text+='```\n'
|
||||
text+="$batt_detail\n"
|
||||
|
@ -382,9 +385,8 @@ fi_disk(){ # 05/10/2017
|
|||
echo -e "$text" >> "$fileOutput"
|
||||
}
|
||||
|
||||
fi_dmesg(){ # 06/10/2017
|
||||
fi_dmesg(){ # 10/10/2017
|
||||
local dmesg_err dmesg_warn dmesg_crit text
|
||||
text="## dmesg (erreur, warning ou critique) \n\n"
|
||||
file="/tmp/$$-$RANDOM-dmesg"
|
||||
[ "$EUID" -eq 0 ] || echo
|
||||
f__sudo "dmesg -Hk --nopager -l err > $file-err ; \
|
||||
|
@ -392,9 +394,9 @@ fi_dmesg(){ # 06/10/2017
|
|||
dmesg -Hk --nopager -l crit > $file-crit ; \
|
||||
chown $user_: $file-*"
|
||||
if [ "$?" != "0" ]; then
|
||||
f__info "\n la commande$GREEN dmesg$RED a échoué $BLUE(droits root requis, échec authentification?)" \
|
||||
"vous pouvez relancer le script complet en root pour voir les erreurs du noyau via dmesg" \
|
||||
"ou juste la partie dmesg avec $GREEN./getInfo -d$STD ou$GREEN getInfo -d$BLUE (script installé)"
|
||||
f__info "raw" "\n la commande$GREEN dmesg$RED a échoué $BLUE(droits root requis, échec authentification?)" \
|
||||
"vous pouvez relancer le script complet$RED en root$BLUE pour voir les erreurs du noyau via dmesg" \
|
||||
"ou juste la partie dmesg avec $GREEN./getInfo -d$BLUE ou$GREEN getInfo -d$BLUE (script installé)"
|
||||
text+="la commande \`dmesg\` a échoué, relancer avec les droits root \n"
|
||||
echo -e "$text" >> "$fileOutput"
|
||||
return 0
|
||||
|
@ -402,8 +404,9 @@ fi_dmesg(){ # 06/10/2017
|
|||
dmesg_err="$(< $file-err)"
|
||||
dmesg_warn="$(< $file-warn)"
|
||||
dmesg_crit="$(< $file-crit)"
|
||||
rm $file-*
|
||||
rm "$file-"*
|
||||
###
|
||||
text="## dmesg (erreur, warning ou critique) \n\n"
|
||||
if [ "$dmesg_warn" ]; then
|
||||
text+='`dmesg -l warn` (warning) \n'
|
||||
text+='```\n'
|
||||
|
@ -517,10 +520,11 @@ et/ou installer le démon Ntp: apt install ntp \n"
|
|||
echo -e "$text" >> "$fileOutput"
|
||||
}
|
||||
|
||||
fi_log_xorg(){ # 06/10/2017
|
||||
fi_log_xorg(){ # 10/10/2017
|
||||
local logXorg text
|
||||
logXorg="$(grep -E '\(WW\)|\(EE\)|\(NI\)|\(\?\?\)' /var/log/Xorg.*.log /home/$user_/.local/share/xorg/Xorg.*.log 2>/dev/null)"
|
||||
###
|
||||
text="## journaux Xorg \n\n"
|
||||
text+='`'"grep -E '\(WW\)|\(EE\)|\(NI\)|\(\?\?\)' /var/log/Xorg.?.log /home/user/.local/share/xorg/Xorg.?.log"'` (xorg.log) \n'
|
||||
text+='```\n'
|
||||
text+="$logXorg \n"
|
||||
|
@ -719,7 +723,7 @@ fi_sources(){ # 09/10/2017
|
|||
printf "."
|
||||
paquetBiz="$(dpkg -l | gawk 'FNR>5 && ! /^i/ {print $1, $2, $3}')"
|
||||
###
|
||||
text+="## sources list \n\n"
|
||||
text="## sources list \n\n"
|
||||
text+='`'"grep -rvE '^#|^$' /etc/apt/sources.list /etc/apt/sources.list.d/*.list 2>/dev/null"'` \n'
|
||||
text+='```\n'
|
||||
text+="$sources \n"
|
||||
|
@ -757,13 +761,24 @@ fi_sources(){ # 09/10/2017
|
|||
}
|
||||
|
||||
# affiche configurations ssid
|
||||
fi_ssid(){ # 08/10/2017
|
||||
fi_ssid(){ # 10/10/2017
|
||||
[ "$(which nmcli)" ] || f__error "il manque NetworkManager"
|
||||
[ $EUID -eq 0 ] || f__error "il manque les droits root"
|
||||
local nm_ssid text
|
||||
nm_ssid="$(grep -vE '#|^$' /etc/NetworkManager/system-connections/*)"
|
||||
local nm_ssid file="/tmp/$$-$RANDOM-fi_ssid" text
|
||||
# nm_ssid="$(grep -vE '#|^$' /etc/NetworkManager/system-connections/*)"
|
||||
[ "$EUID" -eq 0 ] || echo
|
||||
f__sudo "grep -vE '#|^$' /etc/NetworkManager/system-connections/* > $file ; \
|
||||
chown $user_: $file"
|
||||
if [ "$?" != "0" ]; then
|
||||
f__info "\n la consultation des connections NetworkManager$RED a échoué$BLUE (droits root requis, échec authentification?)" \
|
||||
"vous pouvez relancer le script$RED en root:$GREEN./getInfo --ssid$STD ou$GREEN getInfo --ssid$BLUE (script installé)"
|
||||
text+="la consultation des connections NetworkManager a échoué, relancer avec les droits root \n"
|
||||
echo -e "$text" >> "$fileOutput"
|
||||
return 0
|
||||
fi
|
||||
nm_ssid="$(< $file)"
|
||||
rm "$file"
|
||||
###
|
||||
f__info "$RED""Attention, la clé du réseau wifi étant visible $STD""aucun rapport n'a été créé"
|
||||
f__info "la$RED clé du réseau wifi étant visible $STD""aucun rapport n'a été créé"
|
||||
text="## configuration(s) ssid networkmanager \n\n"
|
||||
text+="$GREEN""grep -vE '#|^$' /etc/NetworkManager/system-connections/*$STD \n\n"
|
||||
text+="$nm_ssid \n\n"
|
||||
|
@ -785,8 +800,8 @@ fi_system_analyse(){ # 25/09/2017
|
|||
echo -e "$text" >> "$fileOutput"
|
||||
}
|
||||
|
||||
fi_systeme(){ # 09/10/2017
|
||||
local mbr description uname bootImage xorg shells lastboot uptime text pluriel
|
||||
fi_systeme(){ # 10/10/2017
|
||||
local mbr description uname bootImage xorg shells lastboot uptime pluriel charge text
|
||||
[ -d /sys/firmware/efi ] && mbr="**EFI**" || mbr="**Legacy (mbr)**"
|
||||
[ -x "/usr/bin/lsb_release" ] && description="$(lsb_release -ds)" #dépend de apt install lsb-release, sur debian, en standard, juste : lsb-base
|
||||
uname="$(uname -rmo)"
|
||||
|
@ -801,16 +816,26 @@ fi_systeme(){ # 09/10/2017
|
|||
# lastboot="$(last -n 1 --time-format iso reboot | gawk 'FNR==1 {sub(/T/," ",$5);print $5}')" # remis à jours en début de mois ?!!
|
||||
lastboot="$(date -r /var/run/utmp '+%d/%m/%Y %H:%M %z')"
|
||||
uptime="$(uptime -p | sed 's/up/depuis/; s/week/semaine/; s/weeks/semaines/; s/days/jours/; s/day/jour/; s/hour[s]*/h/; s/minute[s]*/mn/')"
|
||||
charge="$(uptime | sed -En 's/.*load average: (.*), (.*), (.*)/\1 \2 \3/; s/,/./gp')"
|
||||
cores="$(sort -u /proc/cpuinfo | grep -c '^core id')"
|
||||
thread="$(grep -c "^processor" /proc/cpuinfo)"
|
||||
|
||||
###
|
||||
figet_cpu
|
||||
figet_gpu
|
||||
figet_distro
|
||||
figet_wm
|
||||
figet_shell
|
||||
figet_disk
|
||||
figet_battery
|
||||
figet_resolution
|
||||
figet_de
|
||||
text="## système \n\n"
|
||||
text+="| | | \n"
|
||||
text+=" --- | --- \n"
|
||||
figet_cpu
|
||||
text+="CPU | **$fget_cpu** \n"
|
||||
figet_gpu
|
||||
text+="GPU | **$fget_gpu** \n"
|
||||
text+="boot | $mbr \n"
|
||||
figet_distro
|
||||
text+="distribution | **$fget_distro** \n"
|
||||
f__architecture || f__info "Architecture non supportée" "vous pouvez contacter contacter $projet $contact si vous voulez aider à parfaire le script"
|
||||
text+='```\n'
|
||||
|
@ -819,25 +844,20 @@ fi_systeme(){ # 09/10/2017
|
|||
text+="uname: $uname \n"
|
||||
text+="$bootImage \n"
|
||||
text+="démon d'initialisation: $initDaemon \n"
|
||||
figet_resolution
|
||||
text+="résolution: $fget_resolution \n"
|
||||
text+="serveur d'affichage: $xorg \n"
|
||||
figet_de
|
||||
text+="desktop (DE): $fget_de \n"
|
||||
figet_wm
|
||||
text+="window manager: $fget_wm \n"
|
||||
figet_shell
|
||||
text+="shell actif: $fget_shell \n"
|
||||
text+="shells installés: $shells \n"
|
||||
figet_disk
|
||||
text+="$part_fix_tot \n"
|
||||
figet_battery
|
||||
if [ "$batt_detail" ]; then
|
||||
[ "$batt_nb" -gt "1" ] && pluriel="(s)"
|
||||
text+="$batt_nb batterie$pluriel présente$pluriel: \n"
|
||||
text+="$(sed -nE 's/^BAT(.*)$/ BAT\1/p' <<< $batt_detail) \n"
|
||||
fi
|
||||
text+="dernier boot: $lastboot, uptime: $uptime \n"
|
||||
text+="charge système depuis les 1, 5 et 15 dernières minutes: $charge \n"
|
||||
text+='```\n\n'
|
||||
echo -e "$text" >> "$fileOutput"
|
||||
}
|
||||
|
@ -860,9 +880,9 @@ fi_usb(){ # 25/09/2017
|
|||
}
|
||||
|
||||
# informations batterie(s), assigne $batt_nb $batt_detail
|
||||
figet_battery(){ # 09/10/2017
|
||||
figet_battery(){ # 10/10/2017
|
||||
local batt_alim batt_unit batt_capa_design batt_capa_full batt_capa_now batt_conso
|
||||
local batt_voltage batt_status batt_sn batt_cycle tempo batt_restant ibat
|
||||
local batt_voltage batt_status batt_sn batt_cycle batt_alarm tempo batt_restant ibat
|
||||
batt_nb="$(ls /sys/class/power_supply/ | grep -c 'BAT')"
|
||||
if [ "$batt_nb" -gt "0" ]; then
|
||||
# extraction valeur
|
||||
|
@ -895,6 +915,8 @@ figet_battery(){ # 09/10/2017
|
|||
batt_status="$(cat $ibat/status 2>/dev/null)"
|
||||
batt_sn="$(cat $ibat/serial_number 2>/dev/null)"
|
||||
batt_cycle="$(cat $ibat/cycle_count 2>/dev/null)"
|
||||
batt_alarm="$(cat $ibat/alarm 2>/dev/null)"
|
||||
[ "$batt_alarm" == "0" ] && unset batt_alarm
|
||||
# calculs
|
||||
if [ "$batt_capa_design" != "na" ] && [ "$batt_capa_full" ]; then
|
||||
batt_sante="$(gawk '{printf "%.1f", $1/$2*100}' <<< "$batt_capa_full $batt_capa_design")"
|
||||
|
@ -933,13 +955,14 @@ figet_battery(){ # 09/10/2017
|
|||
[ "$batt_capa_design" != "na" ] && batt_detail+="pleine charge théorique: $batt_capa_design $batt_unit => "
|
||||
[ "$batt_sante" ] && batt_detail+="$batt_sante % (indicateur santé)"$'\n'
|
||||
[ "$batt_restant" ] && batt_detail+="$batt_restant"$'\n'
|
||||
[ "$batt_alarm" ] && batt_detail+="alarme batterie: $batt_alarm"$'\n'
|
||||
done
|
||||
batt_detail="$(sed 's/\n//' <<< $batt_detail)"
|
||||
fi
|
||||
}
|
||||
|
||||
figet_cpu(){ # thanks neofetch, assigne $fget_cpu # 09/10/2017
|
||||
local cpu speed_dir temp_dir speedMin speed speedMin speed temp cores
|
||||
figet_cpu(){ # thanks neofetch, assigne $fget_cpu $fget_core # 10/10/2017
|
||||
local cpu speed_dir temp_dir speedMin speed speedMin speed temp cores thread plurielc plurielt
|
||||
cpu="$(gawk -F ': | @' '/model name|Processor/ {printf $2; exit}' /proc/cpuinfo)"
|
||||
speed_dir="/sys/devices/system/cpu/cpu0/cpufreq"
|
||||
temp_dir="/sys/class/hwmon/hwmon0/temp1_input"
|
||||
|
@ -960,8 +983,8 @@ figet_cpu(){ # thanks neofetch, assigne $fget_cpu # 09/10/2017
|
|||
temp="[${temp/${temp: -1}}.${temp: -1}°C]"
|
||||
fi
|
||||
# Show/hide hyperthreaded cores
|
||||
cores="$(grep "^core id" /proc/cpuinfo | sort -u | grep -c '.')" # physique
|
||||
coresT="$(grep -c "^processor" /proc/cpuinfo)" # logique
|
||||
cores="$(sort -u /proc/cpuinfo | grep -c '^core id')"
|
||||
thread="$(grep -c "^processor" /proc/cpuinfo)"
|
||||
# Fix for speeds under 1ghz
|
||||
if [[ -z "${speed:1}" ]]; then speed="0.${speed}"; else speed="${speed:0:1}.${speed:1}"; fi
|
||||
if [[ -z "${speedMin:1}" ]]; then speedMin="0.${speedMin}"; else speedMin="${speedMin:0:1}.${speedMin:1}"; fi
|
||||
|
@ -979,8 +1002,11 @@ figet_cpu(){ # thanks neofetch, assigne $fget_cpu # 09/10/2017
|
|||
cpu="${cpu//Eight-Core}"
|
||||
cpu="${cpu//Core}"
|
||||
cpu="${cpu//with Radeon * Graphics}"
|
||||
# Add cpu cores to output
|
||||
cpu="${cpu/@/(${cores})phys. (${coresT})logi. @}"
|
||||
# Add cpu cores & threads to output
|
||||
[ "$cores" -gt 1 ] && plurielc="s"
|
||||
[ "$thread" -gt 1 ] && plurielt="s"
|
||||
cpu="${cpu/@/($cores core$plurielc-$thread thread$plurielt) @}"
|
||||
fget_core="$cores core$plurielc-$thread thread$plurielt"
|
||||
fget_cpu="$cpu"
|
||||
}
|
||||
|
||||
|
@ -1354,13 +1380,15 @@ fipaste(){
|
|||
# à tester fipaste_curl_markdownshare "$fileOutput"
|
||||
}
|
||||
|
||||
fipaste_curl_pastery(){ # $1 fichier à exporter, $2 durée de conservation en jour; $3 debug # 05/10/2017
|
||||
fipaste_curl_pastery(){ # $1 fichier à exporter, $2 durée de conservation en jour; $3 debug # 10/10/2017
|
||||
[ -e "$1" ] || f__error "fichier $1 inexistant"
|
||||
local curl id
|
||||
local curl id pluriel
|
||||
# curl -X POST "https://www.pastery.net/api/paste/?title=getInfo&language=markdown" -F file=@$1
|
||||
curl="$(curl --silent -X POST "https://www.pastery.net/api/paste/?title=getInfo_$version&language=markdown&duration=$(($2*1440))" --data-binary @$1)"
|
||||
id="$(echo $curl | cut -d '"' -f 4)"
|
||||
f__info "\n\n votre paste:$GREEN https://www.pastery.net/$id/"
|
||||
[ "$pasteDuration" -gt 1 ] && pluriel="s"
|
||||
f__info "\n votre paste:$GREEN https://www.pastery.net/$id/" \
|
||||
"(valide pendant $RED$pasteDuration jour$pluriel)"
|
||||
[ "$3" == "debugPaste" ] && echo -e "\n$curl\n"
|
||||
|
||||
# ?api_key=<api_key>
|
||||
|
@ -1551,10 +1579,10 @@ prg_3(){ # fin de traitements
|
|||
echo -e "[$script $version]($urlNotice) - $dateRapport\n" >> "$fileOutput"
|
||||
f__dialog_oui_non "non" "\n\n exporter sur le pastebin par défaut?" && fipaste
|
||||
f__info "le rapport est disponible en local, fichier:$YELLOW $fileOutput" \
|
||||
"vous pouvez le visualiser plus tard avec $GREEN$script -l" \
|
||||
"vous pourrez l'exporter plus tard sur le pastebin avec $BLUE$script -p"
|
||||
"vous pouvez le visualiser ultérieurement avec $GREEN$script -l" \
|
||||
"vous pourrez l'exporter ultérieurement avec $BLUE$script -p"
|
||||
}
|
||||
prg_menu(){ # menu
|
||||
prg_menu(){ # 10/10/2017
|
||||
|
||||
function display_menu {
|
||||
local centre=50 left=2 larg=60 reply line
|
||||
|
@ -1570,10 +1598,10 @@ function display_menu {
|
|||
}
|
||||
|
||||
printf " $GREEN$script -h$STD : afficher l'aide \n"
|
||||
display_menu "$GREEN$script -c$RED""s$STD : détail catégorie système" \
|
||||
"$GREEN$script -c$RED""c$STD : détail catégorie configuration"
|
||||
display_menu "$GREEN$script -c$RED""r$STD : détail catégorie réseau" \
|
||||
"$GREEN$script -c$RED""a$STD : détail catégorie analyse"
|
||||
display_menu "$GREEN$script -c$RED""s$STD : catégorie système" \
|
||||
"$GREEN$script -c$RED""c$STD : catégorie configuration"
|
||||
display_menu "$GREEN$script -c$RED""r$STD : catégorie réseau" \
|
||||
"$GREEN$script -c$RED""a$STD : catégorie analyse"
|
||||
echo -e "\n\n les catégories peuvent être cumulées: \n" \
|
||||
" $GREEN$script -c$RED""sa$STD générera un rapport sur le système & l'analyse"
|
||||
printf "\n choix des catégories à générer (all pour toutes)? "
|
||||
|
@ -1608,9 +1636,6 @@ options=$@
|
|||
# traitement option
|
||||
for j in $options; do
|
||||
case $j in
|
||||
--debug-batt )
|
||||
optDebug="debugBatt"
|
||||
;; # si debug, affichage /sys/class/power_supply/BAT?/uevent
|
||||
--debug-paste )
|
||||
optDebug="debugPaste"
|
||||
;; # si debug, retour json de pastery.net
|
||||
|
@ -1620,15 +1645,15 @@ for j in $options; do
|
|||
esac
|
||||
done
|
||||
unset j
|
||||
options="$(sed -E 's/--debug-paste//g; s/--debug-batt//g; s/-t[0-9]+//g' <<< $options | xargs)" # nettoyage options
|
||||
options="$(sed -E 's/--debug-paste//g; s/-t[0-9]+//g' <<< $options | xargs)" # nettoyage options
|
||||
[ "$options" == "" ] && options="all"
|
||||
|
||||
[ "$pasteDuration" ] || pasteDuration=7 # durée de conservation standard du paste en jours
|
||||
fileOutput="getInfo_rapport.md"
|
||||
fileLogs="/var/log/sdeb_$script.log"
|
||||
fileDev="/opt/bin/fileDev"
|
||||
urlScript="https://frama.link/getinfo"
|
||||
urlNotice="https://frama.link/doc-getinfo"
|
||||
urlScript="https://frama.link/getInfo"
|
||||
urlNotice="https://frama.link/doc-getInfo"
|
||||
if [[ "$options" =~ all|-d|-h|-c ]]; then
|
||||
if ! f__wget_test "$urlScript" "test"; then
|
||||
urlScript="https://framagit.org/kyodev/kyopages/raw/master/scripts/$script"
|
||||
|
@ -1650,19 +1675,14 @@ for j in $options; do
|
|||
prg_1
|
||||
fi_reseau
|
||||
prg_3
|
||||
exit ;;
|
||||
all | -c* )
|
||||
exit ;; # test seulement
|
||||
-c* | all )
|
||||
[ "$j" == "-c" ] && exec $0 "menu"
|
||||
prg_1
|
||||
j=$(sed -E 's/-c//' <<< $j)
|
||||
prg_2 "$j"
|
||||
prg_3
|
||||
exit ;;
|
||||
-d )
|
||||
prg_1
|
||||
fi_dmesg "dmesg"
|
||||
prg_3
|
||||
exit ;; # rapport dmesg only, root requis
|
||||
exit ;; # rapport complet ou par catégorie
|
||||
-l )
|
||||
[ -e $fileOutput ] && cat $fileOutput || f__info "pas de rapport à afficher" \
|
||||
"vous devez lancer une analyse auparavant: $GREEN$script -l" \
|
||||
|
@ -1674,11 +1694,18 @@ for j in $options; do
|
|||
-h )
|
||||
f_help
|
||||
exit ;; # affichage help
|
||||
--batt )
|
||||
--debug-batt )
|
||||
optDebug="debugBatt"
|
||||
prg_1
|
||||
fi_batt
|
||||
prg_3
|
||||
exit ;;
|
||||
exit ;; # rapport batterie avec affichage /sys/class/power_supply/BAT?/uevent
|
||||
--dmesg )
|
||||
prg_1
|
||||
fi_log_xorg
|
||||
fi_dmesg "dmesg"
|
||||
prg_3
|
||||
exit ;; # rapport dmesg & log xorg, root requis
|
||||
--ip )
|
||||
if figet_ip_public "4" ; then
|
||||
f__info "raw" " ipv4 publique: $GREEN$ip_public"
|
||||
|
|
|
@ -8,10 +8,19 @@
|
|||
* option erreur pour f__info?
|
||||
* revoir figet_ip, gateway
|
||||
* éviter 169.254.10.12/16 ( enp3s0 ) (ethernet) si non branché
|
||||
* alarm batterie
|
||||
---
|
||||
|
||||
|
||||
## 2.1.0 10/10/2017
|
||||
|
||||
* fi_ssid: géré via f__sudo (oubli)
|
||||
* fi_systeme: charge système
|
||||
* figet_cpu: révision présentation et $fget_core
|
||||
* option --dmesg au lieu de -d + log xorg
|
||||
* révision help
|
||||
* alarm batterie éventuelle
|
||||
* fix fi_batt: pas d'affichage si pas de batterie
|
||||
|
||||
## 2.0.0 09/10/2017
|
||||
|
||||
* révision option debug
|
||||
|
@ -72,9 +81,9 @@
|
|||
|
||||
* f__wget_test: correction code retour lors "test"
|
||||
* fi_sources:
|
||||
* révision
|
||||
* nb de packages installés
|
||||
* mieux date dernier apt update
|
||||
* révision
|
||||
* nb de packages installés
|
||||
* mieux date dernier apt update
|
||||
* figet_cpu, remplacement wc -l par grep -c
|
||||
* plus de dépendances wc
|
||||
* figet_battery: voltage, conso si 0
|
||||
|
@ -161,8 +170,8 @@ fix bug: id resume dans fi_disk
|
|||
|
||||
* nouveau IFS
|
||||
* révision figet_ip:
|
||||
* ifnames, toutes les interfaces et pas seulement les connectées
|
||||
* mac address des interfaces
|
||||
* ifnames, toutes les interfaces et pas seulement les connectées
|
||||
* mac address des interfaces
|
||||
* révision affichage fi_ssid
|
||||
* fix bug: export direct après génération rapport
|
||||
* nouveau: option affichage adresses mac
|
||||
|
@ -268,25 +277,3 @@ fix bug: id resume dans fi_disk
|
|||
* get_distro(neofetch)
|
||||
* révision protection variables
|
||||
* désactivation affichage ipv6 en attente meilleur filtrage
|
||||
|
||||
|
||||
|
||||
|
||||
## notes
|
||||
|
||||
bug markdownshare:
|
||||
'```' pas interprêté en <pre><code>
|
||||
|
||||
style.css ligne 167
|
||||
pre {
|
||||
padding:10px;
|
||||
margin:0 0px 20px 0px;
|
||||
font-size:0.8em
|
||||
}
|
||||
|
||||
toc auto markdown:
|
||||
http://ndossougbe.github.io/strapdown/
|
||||
|
||||
https://www.pastery.net/api/
|
||||
license non libre? pas de depot, mais ça marche
|
||||
|
||||
|
|
Loading…
Reference in New Issue