powershell new folder 1

powershell new folder

New-Item -ItemType directory -Path C:\Scripts\newDir

Here is what the above code is Doing:
1. We’re creating a new directory called newDir in the C:\Scripts directory.
2. We’re using the New-Item cmdlet to create the new directory.
3. We’re using the -ItemType parameter to specify that we want to create a directory.
4. We’re using the -Path parameter to specify the path to the new directory.

Similar Posts