步驟1:將AppleScript圖標添加到OSX菜單欄
在AppleScript編輯器內部(在OSX應用程序-實用工具中)轉到首選項-常規,然后選中
[x]菜單欄中的顯示腳本菜單
步驟2:將此腳本添加到用戶腳本中
-- H.Zimmerman, AppleScript.
-- Create text file in current Finder folder with a dialog.
tell application “Finder”
try
display dialog “name of doc please (without the .txt thing)” default answer “”
set fileName to the text returned of result
if length of fileName = 0 then
return 0
end if
set fileExt to “.txt”
set thisFolder to the target of the front window as alias
set newFile to fileName & fileExt
make new file at thisFolder with properties {name:newFile, file type:“TEXT”, creator type:“ttxt”}
on error errMsg
display dialog (errMsg)
end try
end tell
步驟3:創建文本文件
在相應的 Finder 文件夾中,只需選擇剛添加的菜單項,輸入名稱,文件即已存在。雙擊它將打開熟悉的文本編輯。
責任編輯:wv
-
編輯器
+關注
關注
1文章
822瀏覽量
32023
發布評論請先 登錄
迅為RK3588開發板Android13系統掛載samba共享文件夾-怎么開啟Windows共享目

TSolidX應用:液晶掩膜結構GDSⅡ文件的生成和導出
在KaihongOS中,可以使用文件管理對文件進行基礎的操作
為什么無法使用圖像文件夾執行對象檢測Python演示?
如何快速創建用戶自定義Board和App工程

hyper v 復制,hyper v 復制如何操作

評論