[powershell] How do I run a PowerShell script when the computer starts?

If you do not want to worry about execution policy, you can use the following and put into a batch script. I use this a lot when having techs at sites run my scripts since half the time they say script didnt work but really it's cause execution policy was undefined our restricted. This will run script even if execution policy would normally block a script to run.
If you want it to run at startup. Then you can place in either shell:startup for a single user or shell:common startup for all users who log into the PC.

cmd.exe /c Powershell.exe -ExecutionPolicy ByPass -File "c:\path\to\script.ps1"

Obviously, making a GPO is your best method if you have a domain and place in Scripts (Startup/Shutdown); under either Computer or User Configurations\Windows Settings\Scripts (Startup/Shutdown). If you go that way make a directory called Startup or something under **

\\yourdomain.com\netlogon\

and put it there to reference in the GPO. This way you know the DC has rights to execute it. When you browse for the script on the DC you will find it under

C:\Windows\SYSVOL\domain\scripts\Startup\

since this is the local path of netlogon.