两年前的东西了,要不是现在 GFW 这么牛逼估计一辈子都用不到。
新建 AppleScript,贴入代码:
on idle tell application "System Events" tell current location of network preferences set myConnection to the service "YOUR VPN NAME" if myConnection is not null then if current configuration of myConnection is not connected then connect myConnection end if end if end tell return TIME end tell end idle