PowerShell .NET Framework Dependency ?

This topic contains 1 reply, has 2 voices, and was last updated by  postanote 2 months, 3 weeks ago.

  • Author
    Posts
  • #95031

    Lockdown
    Participant

    In the "Learn PowerShell in a Month of Lunches", section 2.1.1. The console window it states that the console uses the bare minimum of .NET Framework as opposed to the ISE. What is the PowerShell .NET Framework dependency ? Is PowerShell running on top of .NET Framework ?

    I am only looking for a basic answer for familiarization and not a deep, technical one.

  • #95044

    postanote
    Participant

    Don't stress out over this, as it's really not a thing.
    It's all in the Windows Management Framework / PowerShell docs. No reason to guess at it.

    Firstly, it is the Windows Management Framework installer that installs PowerShell bits.

    PowerShell can access .Net just like other languages. It's not something that runs on top of it. That is not a thing. That being said, different WMF versions require a specific .Net version, and newer .Net versions of course have more features and improvements.

    With the exception of PowerShellCore (PowerShellv6 – a separate installer and separate .Net install required), which is cross platform (Win/OSX/Linux) and a far different thing than the built-in Windows PowerShell.

    Every version of Windows form Windows 7 to Server 2016, the Windows Management Framework required version is already on the box. There is nothing for you to do but use it. Each version of the OS with come with the default WMF(PowerShell) version. However, you can upgrade to new versions as needed for the OS version you are running.

    Each of the Windows Management Framework (PowerShell) actually list all the system requirement for each version.
    Upgrading existing Windows PowerShell

    The installation package for PowerShell comes inside a WMF installer. The version of the WMF installer matches the version of PowerShell; there's no stand alone installer for Windows PowerShell.

    If you need to update your existing version of PowerShell, in Windows, use the following table to locate the installer for the version of PowerShell you want to update to.

    'docs.microsoft.com/en-us/powershell/scripting/setup/installing-windows-powershell?view=powershell-5.1'

    .Net is in Windows by default, whether you ever use PoSH or not. The .Net Framework will also auto update during normal update cycles per the version you are running.

    The .Net requirement is part of WMF. The ISE is a full-blown scripting IDE specifically for PowerShell, and there are features in the ISE that are not in the PowerShell Console host and there are things that work better in the console host than in the ISE.

    Think of the PoSH console host (powershell.exe) as you cmd.exe replacement.
    The ISE (powershell_ise.exe) a true script editor.

    So, if you are banging out normal command line stuff, the console host is the normal target for most.
    If you are writing scripts (functions, modules, forms, applications), the ISE is your target.

    Upgrading existing Windows PowerShell

    The installation package for PowerShell comes inside a WMF installer. The version of the WMF installer matches the version of PowerShell; there's no stand alone installer for Windows PowerShell.

    If you need to update your existing version of PowerShell, in Windows, use the following table to locate the installer for the version of PowerShell you want to update to.

    'docs.microsoft.com/en-us/powershell/scripting/setup/installing-windows-powershell?view=powershell-5.1'

You must be logged in to reply to this topic.