Pain points

The switch Host tool on the market changes the hosts, but chrome has its own DNS cache, which takes a few minutes to update. Either wait, or open a new invisible window (but cookies will be lost), which affects the work pace. So electron developed the switch host tool with Flush socket pools.

Use guide

The tool supports only MAC operating systems, and the browser must be Chrome

Just three steps:

Step 1: Set the host file modification permission

sudo chmod 777 /etc/hosts

Step 2: Set Chrome permissions

Chrome, View -> Developer -> allows JavaScript in Apple events

Step 3: Install tools

↓↓↓ See the version information at the bottom

Add the host

Save, turn host on/off (same as other swith hosts)

The host file will be written to the local host file when the host is saved, enabled, or disabled:

cat /etc/hosts
Copy the code

Tips: It will persist only when saved, otherwise it will disappear when cut again

After the save, the application will automatically perform chorme’s Flush socket pools, and the first time there will be a prompt for permission permission, select Agree.

Matters needing attention

  • Close other swith host tools while using, otherwise there will be a privilege contention problem. If this situation causes problems, close the other tools and restart sudo chmod 777 /etc/hosts

Version information

1.3.0

Switch the Host Egg – 1.3.0. DMG

changelog:
  • Added search function -command + F
  • Modifying closed host does not refresh Chrome
  • Refresh Chrome increases debounce to 1.5 seconds to avoid too many refreshes