Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // implementation
- function open_folder(dname) {
- var escapedfolder = string_replace_all(dname, "\"", "\\\"");
- if (os_type = os_windows) execute_shell("cmd", "explorer \"" + escapedfolder + "\"");
- else if (os_type = os_macosx) execute_shell("open", "\"" + escapedfolder + "\"");
- else if (os_type = os_linux) execute_shell("xdg-open", "\"" + escapedfolder + "\"");
- }
- // usage example
- open_folder(working_directory);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement