Skip to content

Instantly share code, notes, and snippets.

@rwilcox
Created November 15, 2011 02:55
Show Gist options
  • Save rwilcox/1365992 to your computer and use it in GitHub Desktop.
Save rwilcox/1365992 to your computer and use it in GitHub Desktop.
Save current open BBEdit documents to Unix Worksheet for later
tell application "BBEdit"
set output to ""
set docs to every project document
repeat with current in docs
repeat 1 times
if file of current is missing value then
exit repeat
end if
set asAlias to file of current as alias
set output to output & "
" & "bbedit '" & POSIX path of asAlias & "'"
end repeat
end repeat
set uws to Unix worksheet window
tell uws
select insertion point after last character
set selection to output
end tell
end tell
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment