Is there a way to open a File Explorer pane using a command in R/R Studio on Windows, with perhaps a path specified as the argument? For example:
open_folder(getwd())
would open File Explorer at the working directory. It would be like the opposite of choose.dir
, in that you go from a path to File Explorer rather than from File Explorer to the path. It would be a command-line version of clicking on Files >> More >> Show Folder in New Window in R Studio.
I don't really know how to write code to work directly with Windows, so I'm looking for something that is already implemented or can be implemented just inside R.