Skip to content

Instantly share code, notes, and snippets.

@mh61503891
Created April 30, 2011 07:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mh61503891/949497 to your computer and use it in GitHub Desktop.
Save mh61503891/949497 to your computer and use it in GitHub Desktop.
Tree to OPML1.0
-- Readme
-- Tree.app1.6.2でOPML1.0でエクスポートするAppleScript.
-- [注意] GUI Scriptingでゴリ押しなのでTree.appのバージョンが違うと誤作動する可能性がある.
-- [注意] 同名の.opmlファイルが存在する場合は上書きされる.
-- References
-- AppleScript Help - Apple - http://docs.info.apple.com/help/guide.html?path=AppleScript/2.1/jp/
-- AppleScriptの構造を上手に調べる - http://allabout.co.jp/gm/gc/80938/3/
tell application "Tree"
activate
tell application "System Events"
tell process "Tree"
pick menu item "Export..." of menu 1 of menu bar item "File" of menu bar 1
tell sheet 1 of window 1
click pop up button 1 of group 1 of group 1
click menu item "OPML1.0" of menu 1 of pop up button 1 of group 1 of group 1
click button "Save"
if exists button "Replace" of sheet 1 then
click button "Replace" of sheet 1
end if
end tell
end tell
end tell
end tell
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment