Copy-Item


Calls a provider to copy an item from one location to another within a namespace.

Snap-In: Microsoft.PowerShell.Management

Syntax:

Copy-Item

 [-Path] <String[]> [ [-Destination] <String>] [-Container] [-Force] [-Filter <String>] [-Include <String[]>] [-Exclude <String[]>] [-Recurse] [-PassThru] [-Credential <PSCredential>] [-Verbose] [-Debug] [-ErrorAction <ActionPreference>] [-ErrorVariable <String>] [-OutVariable <String>] [-OutBuffer <Int32>] [-WhatIf] [-Confirm] 

Description:

Copy-item Cmdlet copies an item from one location to another in a namespace. It is roughly equivalent to the 'cp' or 'copy' commands from other shells. Note that a directory specified as path does not automatically expand to the files in that directory. Use the syntax directory/* to indicate all the files. If the expansion of the directory includes a subdirectory, and - Recurse or -Container is not t rue, then copy-item will copy the files over, but not the subdirectories. Next, produce the following warning:

The source and destination paths are both containers, yet recurse was not specified. In order to copy a container into another container, the container parameter must be true.



Windows PowerShell. TFM
Internet Forensics
ISBN: 982131445
EAN: 2147483647
Year: 2004
Pages: 289

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net