Advertisement
Guest User

GUI env checker

a guest
Apr 26th, 2010
295
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. -- This AppleScript displays a dialog with info
  2. -- (environment variables, current folder, etc)
  3. -- about the execution environment seen by GUI apps.
  4. -- It also puts this info on the clipboard.
  5. -- Run it from Script Editor or save it as an application
  6. -- and run it via double-clicking.
  7.  
  8. set envVars to (do shell script "/usr/bin/printenv")
  9. set cwd to (do shell script "/bin/pwd")
  10. set envVarsStr to "Environment Variables:" & return & envVars
  11. set cwdStr to "Current Folder:" & return & cwd
  12. set info to envVarsStr & return & return & cwdStr
  13. set the clipboard to info
  14. display dialog info buttons {"OK"}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement