GeekTool中使用Things

/ 0评 / 1

1.建立applescript文件

我在目录下新建一个scpt文件,内容如下:

#!/usr/bin/osascript 
--this line checks if Things is running when this script is launched 
tell application "System Events" to set alreadyrunning to exists (processes where name is "Things")

--this makes a line break between todos 
set AppleScript's text item delimiters to {(ASCII character 10)}

tell application "Things"
	
	log completed now --don't want to see completed tasks 
	set todos to name in to dos of list "Today" as string
	if not alreadyrunning then quit --if ran by me then quit 
	return todos
	
end tell

2.GeekTool中输入代码

echo Today To-Dos List
echo
osascript /Users/things.scpt

这样就可以在桌面显示Things Today的To Do List了~

发表评论

邮箱地址不会被公开。 必填项已用*标注