{"id":28,"date":"2008-01-26T21:58:24","date_gmt":"2008-01-26T20:58:24","guid":{"rendered":"http:\/\/www.chipwreck.de\/blog\/2008\/01\/26\/open-the-terminal-with-path-set-to-given-location\/"},"modified":"2016-12-31T02:06:00","modified_gmt":"2016-12-31T01:06:00","slug":"open-the-terminal-with-path-set-to-given-location","status":"publish","type":"post","link":"https:\/\/www.chipwreck.de\/blog\/2008\/01\/26\/open-the-terminal-with-path-set-to-given-location\/","title":{"rendered":"Open the terminal with path set to given location"},"content":{"rendered":"<p>Useful for an automator action for example:<\/p>\n<pre lang=\"applescript\">\r\n-- Open terminal at given path\r\n-- \r\n-- From: www.chipwreck.de\r\n\r\nset p to POSIX path of (item 1 of i as alias) -- define i\r\n\t\r\ntell application \"Terminal\"\r\n\r\n\tactivate\r\n\tdo script \"cd \\\"\" & p & \"\\\"\"\r\n\tclose window 2\r\n\t\r\nend tell\r\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>Useful for an automator action for example: &#8212; Open terminal at given path &#8212; &#8212; From: www.chipwreck.de set p to POSIX path of (item 1 of i as alias) &#8212; define i tell application &#8220;Terminal&#8221; activate do script &#8220;cd \\&#8221;&#8221; &#038; p &#038; &#8220;\\&#8221;&#8221; close window 2 end tell<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[4],"tags":[12,78],"class_list":["post-28","post","type-post","status-publish","format-standard","hentry","category-osx","tag-applescript","tag-osx"],"jetpack_featured_media_url":"","jetpack_shortlink":"https:\/\/wp.me\/paPEN-s","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/www.chipwreck.de\/blog\/wp-json\/wp\/v2\/posts\/28","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.chipwreck.de\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.chipwreck.de\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.chipwreck.de\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.chipwreck.de\/blog\/wp-json\/wp\/v2\/comments?post=28"}],"version-history":[{"count":0,"href":"https:\/\/www.chipwreck.de\/blog\/wp-json\/wp\/v2\/posts\/28\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.chipwreck.de\/blog\/wp-json\/wp\/v2\/media?parent=28"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.chipwreck.de\/blog\/wp-json\/wp\/v2\/categories?post=28"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.chipwreck.de\/blog\/wp-json\/wp\/v2\/tags?post=28"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}