반응형
크롬 메뉴->방문기록->홈
tell application "System Events" to tell process "Chrome"
click menu item "홈" of menu 1 of menu bar item "방문기록" of menu bar 1
end tell
터미널로 실행
osascript [스크립트 경로]
obj-c로 실행
NSTask *task = [[NSTask alloc] init];
task.launchPath = @"/usr/bin/osascript";
task.arguments = @[스크립트 경로];
[task launch];
반응형