Site original : shaarli-Links
LOL
Même le zoom de Firefox fait mieux que OJOY.
— Permalink
Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)
Pas super rassurant qu'une société privée prenne des décisions sur le fonctionnement de votre maison.
The service can alert you if Alexa picks up on certain types of sounds in your home and offers access to human agents who can call emergency services on your behalf, similar to ADT
Je sent la connerie arriver.
— Permalink
Se passer des « if »
Oui, ... mais non.
Niveau optimisation des actions, c'est pas top.
// avec if
$count = 0;
foreach ($data as $value) {
if ($value === CONTROL_VALUE) {// 1 action
$count++; // 1 action si condition vrai
}
}
// sans if
$count = 0;
foreach ($data as $value) {
$count += (int) ($value === CONTROL_VALUE);// 3 actions quelques soit la valeur de value
/*
+= : 1 action
(int) : 1 action
=== : 1 action
*/
}
Bloquez et cassez vos while
C'est débile les while true. Ça consomme des ressources pour rien.
$block = 0; // 1 action
while (true) { // 1 action
$block++; // 1 action
if ($block > 1000) { // 1 action
break; // 1 action
}
}
3 actions par tour de boucle.
$block = 0; // 1 action
while ($block < 1001) { // 1 action
$block++; // 1 action
}
2 actions par tour de boucle.
— Permalink
Renommer une interface réseau
echo "[Match]
MACAddress=00:0d:b9:49:8a:18
[Link]
Name=uplink0
"> /etc/systemd/network/10-uplink0.link
update-initramfs -u
reboot
:-)
— Permalink
Cool :-p
https://github.com/Nuand/bladeRF-wiphy/
— Permalink
fail2ban et modsecurity, c'est fait pour ça ;-)
— Permalink
T'as aussi :
sudo apt install anarchism
firefox /usr/share/doc/anarchism/html/index.html
Interface web pour aria2
https://github.com/mayswind/AriaNg
https://github.com/aria2/aria2
— Permalink