This is handy to know...
Use powershell files as an example…add a ps1 file to a solution (just create an empty solution of any type), right click on the document in Solution Explorer and choose “Open with..”, browse and choose the Powershell GUI Editor program, the press Set as Default.