Getting Tasker to Pass Network Configuration to Minimalistic Text (and other apps)

I’ve got a cool little banner on my homescreen of my Android, consisting of the time and the current network settings – whether it’s on wifi, cell data, or even if it’s on a VPN. It also displays the current IP address on the LAN and out to the internet.

It does this with the power of Tasker and the shell in Android (which you can access without root).

In short, it runs netcfg when you connect (or disconnect) to a network, then parses that input until it finds out what kind of connection you’re on. It also finds the SSID of the network (if applicable) and the IP addresses by calling out to https://checkip.dyndns.org/ and parsing that output. It then stores it all and puts it in variables for Minimalistic Text.

You can find the project as wifi.prj.xml (if you’re on your phone now, you should be able to click that link directly and import it) on my GitHub collection of Tasker tasks. I bundled this as a project, so you should be able to just import it.

If you don’t know how to import a project into Tasker, there’s a HOWTO right here: https://almost-a-technocrat.blogspot.com/2013/04/how-to-import-tasker-projects-profiles.html