LazyMagic

How to Install PowerShell 7 for LazyMagic

⚡ Quick Answer

To install PowerShell 7 for LazyMagic: Download PowerShell 7 from Microsoft, open it as administrator, check execution policy with Get-ExecutionPolicy, and set it to RemoteSigned with Set-ExecutionPolicy RemoteSigned if needed.

Prerequisites

  • ✅ Administrator access on your Windows workstation
  • ⏱️ Estimated time: 5 minutes
  • 💰 Cost: Free

What is PowerShell 7?

PowerShell 7 is Microsoft's cross-platform command-line shell and scripting language. LazyMagic requires PowerShell 7 for its deployment automation and AWS integration scripts.

Step-by-Step Installation Guide

Step 1: Install PowerShell 7

Download and install PowerShell 7 from Microsoft's official documentation:

Step 2: Configure Execution Policy

LazyMagic requires the ability to run PowerShell modules. Follow these steps to configure the execution policy:

2.1 Open PowerShell as Administrator

  1. Search for "PowerShell" in the Windows Start menu
  2. Right-click on the PowerShell 7 application
  3. Select "Run as administrator"

2.2 Check Current Execution Policy

Run this command to check your current execution policy:

Get-ExecutionPolicy

2.3 Set RemoteSigned Policy (if needed)

If the policy is not RemoteSigned or Unrestricted, run:

Set-ExecutionPolicy RemoteSigned

This allows locally-created scripts to run while requiring downloaded scripts to be signed.

Verification

To verify PowerShell 7 is properly installed and configured:

  1. Open a new PowerShell 7 window
  2. Run: $PSVersionTable.PSVersion
  3. Confirm the version shows 7.x or higher
  4. Run: Get-ExecutionPolicy
  5. Confirm it shows "RemoteSigned" or "Unrestricted"

Troubleshooting

Common Issues

  • Access Denied: Make sure you're running PowerShell as Administrator
  • Old PowerShell Version: Ensure you installed PowerShell 7, not Windows PowerShell 5.1
  • Policy Won't Change: You may need Group Policy permissions in enterprise environments

Next Steps

After successfully installing PowerShell 7, proceed to install the Git CLI in the next step of the LazyMagic setup process.