zkapp-cli
zkapp-cli copied to clipboard
Show message in CLI when user is not connected to the internet after entering zk project [name] --ui [framework]
trafficstars
Background: We designed the CLI previously to work offline (from cache), but the UI framework install commands require internet access
I implemented something similar for a personal project recently. My solution was to do a DNS lookup for a common domain that can be expected to be online (e.g. google.com) and if a result is returned, you're online.
It would be nice if this didn't occur unless an error occurred and were diagnosing it though, for privacy.