Run a comamnd after network-online.target is ready

tl;dr: Use this shell command in my crontab: @reboot sh -c "while ! systemctl status network-online.target > /dev/null; do sleep 1; done; exec /foo/bar.sh" The problem I've encountered is, sometimes /foo/bar.sh would failed at boot. After digging into details, I found it's because the network was not ready, therefore the script could not get network …

Flutter + auto hot reload/restart in console (CLI)

Flutter in CLI (mainly flutter run) cannot auto hot reload by itself in Linux, so we need to setup some commands to trigger it. The basic idea is to use inotifywait in inotify-tools (which is already in Debian/Ubuntu's APT repository): inotifywait -e create,delete,modify -mr android/ lib/ | awk "{system(\"test -e .git/flutter-run.pid && pkill -USR1 -F …