dustinrue / ControlPlane

ControlPlane - context-sensitive computing for OS X
http://www.controlplaneapp.com
BSD 3-Clause "New" or "Revised" License
1.76k stars 180 forks source link

get current context only returns leaf node #293

Open arobinson opened 11 years ago

arobinson commented 11 years ago

In the WIKI there is this code to get the current context via apple script:

tell application "ControlPlane"
    get current context
end tell

The issue is that my ControlPlane setup looks like:

Automatic
Home
  |--Wired
  \--Wireless
Work
  |--Wired
  |--Wireless
  \--VPN

So "VPN" is pretty much a given, but if I get back "Wired", I have no idea if it is "Home/Wired" or "Home/Wireless". Is there a way to get the full context not just the leaf node?

VladimirTechMan commented 11 years ago

Thanks for the report, Andrew. Yes, you're right, that is a regression with 1.4.0. I've just pushed the fix for it to the master branch. And the next public release of CP will have it on board. Meantime, I can send you a custom build that fixes this issue if you want so. For that I will need your e-mail. Let me know.

Vladimir

arobinson commented 11 years ago

It is not killing me, I can work around the issue until the next version is released. Thank you

arobinson commented 10 years ago

FYI, I'm using the git source code (1.4.1) and this is working fine so far