用Linux命令行玩Google服務(wù) GoogleCL項(xiàng)目啟動(dòng)
想通過(guò)一個(gè)命令行提示符將一個(gè)文件夾內(nèi)的所有照片上傳到Picasa?現(xiàn)在你可以用GoogleCL了。
Google宣布了新命令行工具GoogleCL,允許用戶(hù)通過(guò)命令行操控Google服務(wù),比如輸入一行命令將一篇文章貼到Blogger,或者將視頻上傳到Y(jié)ouTube,將照片上傳到Picasa,為Calendar添加新活動(dòng)日程,甚至在Google Docs上編輯文檔。
GoogleCL工具主要是面向Linux用戶(hù),Mac和Windows用戶(hù)也可以用,不過(guò)要費(fèi)些周折,用戶(hù)需要有Python 2.5 或2.6,Windows用戶(hù)還需要Cygwin。
以下是針對(duì)各Google服務(wù)的相關(guān)Linux命令:
Blogger:發(fā)布文章到Google博客
$ google blogger post --title "foo" "command line posting"
Calendar:添加事件到Google日歷
$ google calendar add "Lunch with Jim at noon tomorrow"
Contacts:導(dǎo)入Google聯(lián)系人
$ google contacts list name,email > contacts.csv
Docs:編輯Google文檔
$ google docs edit --title "Shopping list"
Picasa:上傳照片并管理相冊(cè)
$ google picasa create --album "Cat Photos" ~/photos/cats/*.jpg
Youtube:上傳視頻
$ google youtube post --category Education killer_robots.avi
相關(guān)命令使用范例可參考項(xiàng)目官方介紹:
http://code.google.com/p/googlecl/wiki/ExampleScripts
【編輯推薦】