View a parent folder of a project
I searched for a certain term and found a project that I don't know in which folder it is and I want to find out the name and place of that folder. How do I do that? I don't see any folder info in "inspect"...
|
Choosing 'Group by Folder' from the View Bar would be one option.
|
(and if you don't want to disturb the state of your view, and folder-tracking seems to be a regular issue, then you can always reach for the universal duct tape, and install a simple applescript button on your toolbar - sth like this):
[CODE]property pTitle : "Show folder path" property pVer : "0.02" tell application id "OFOC" tell front document window of front document repeat with oPanel in {content, sidebar} set lstValue to value of (selected trees of oPanel where class of its value is project or class of its value is task) if length of lstValue > 0 then exit repeat end repeat if length of lstValue < 1 then return display dialog my FolderPath(first item of lstValue) buttons {"OK"} default button "OK" with title pTitle & " ver. " & pVer end tell end tell on FolderPath(oNode) set str to "" tell application id "OFOC" set oParent to container of (containing project of oNode) repeat while class of oParent = folder set str to name of oParent & ":" & str set oParent to container of oParent end repeat end tell return str end FolderPath[/CODE] |
RobTrew, thank you!
|
I prefer a slight modification to Rob's script, which prints the name of the project as well. This allows one to run it with just an action selected and get the full name, useful in cases where you don't have the project name displayed.
[code] property pTitle : "Show folder path" property pVer : "0.03" tell application id "OFOC" tell front document window of front document repeat with oPanel in {content, sidebar} set lstValue to value of (selected trees of oPanel where class of its value is project or class of its value is task) if length of lstValue > 0 then exit repeat end repeat if length of lstValue < 1 then return display dialog my FolderPath(first item of lstValue) buttons {"OK"} default button "OK" with title pTitle & " ver. " & pVer end tell end tell on FolderPath(oNode) set str to "" tell application id "OFOC" set oParent to container of (containing project of oNode) repeat while class of oParent = folder set str to name of oParent & ":" & str set oParent to container of oParent end repeat set str to str & name of (containing project of oNode) end tell return str end FolderPath [/code] |
Very helpful. I'd also vote for a context menu (control-click) item along the lines of "show parent" or "show containing".
|
All times are GMT -8. The time now is 07:36 AM. |
Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2024, vBulletin Solutions, Inc.