O'Reilly logo

Windows Server® 2012 Unleashed by Chris Amaris, Andrew Abbate, Omar Droubi, Guy Yardeni, Michael Noel, Rand Morimoto

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Managing the Files and Directories

As mentioned earlier in this chapter, specifically in the section “Providers,” a set of core cmdlets can be used to access and manipulate PowerShell data stores. Because the Windows file system is just another PowerShell data store, it is accessed through the FileSystem provider. Each mounted drive or defined location is represented by a PSDrive and can be managed by using the core cmdlets. Details about how these core cmdlets are used are discussed in the following sections.

Listing Directories of Files

In PowerShell, you can use several cmdlets to explore the file system. The first cmdlet, Get-Location, is used to display the current working location:

PS C:\> get-locationPath----C:\PS C:\>

To get information ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required