Power Shell Tutorial for Beginners
Windows PowerShell is one of the free scripting applications preinstalled in Windows machine or directly can be downloaded from Windows official website. From windows 7 onwards Microsoft introduced Powershell.ise where we can test our scripts and later save them in .ps1 format. Although there are many advantages of using Powershell our main use is to automate things so that we can save time and manual work.
Today, Powershell comes with great cmdlets that can be used to run in any specific application-related servers that can be SQL, Sharepoint, etc. Well, everything can be automated with Powershell. Although sometimes it is highly recommended to do things manually as the world is progressing to achieve automation and cut manual tasks it is really important to cope with moving technologies.
In this section, we will understand How to open Powershell from Windows.
There are many ways to open Powershell let’s check one by one .
Step 1) From the start menu, just search for Powershell and there you go.
Step 2) From the command prompt (cmd).
Step 3) From Run.exe, we just need to type Powershell and the Powershell window will open.
Below are some of the reasons you should use Powershell.
Below is the command which we will use to find out the Powershell Version. This is one of the basic commands we will learn in today’s post.
$PSVersionTable
PS
command prompt to appear.Navigate to the directory where the script lives
PS> cd C:\my_path\yada_yada\
Execute the script:
PS> .\run_import_script.ps1
Or
You can run the PowerShell script from cmd.exe
like this:
powershell -noexit "& ""C:\run_import_script.ps1"""