Open with Powershell--Associate .ps1 File Type Extension with PowerShell
The .ps1 extension is also known as a file type.
https://www.lifewire.com/how-to-change-file-associations-in-windows-2624477
Win 11 Interface
Open Control Panel
Select Programs > Default Programs
Select Associate a file type or protocol with a program
Default apps
Choose default apps by file type
Select .ps1 under the Name column on the left.