Collections:
Other Resources:
Move Directory or File in Windows PowerShell
How to move a directory or file to a new location in Windows PowerShell? Can I use the old "move" command?
✍: FYIcenter.com
Yes, you can still use the old "move" command in Windows PowerShell.
But "move" is defined as an alias of the "Move-Item" cmdlet.
The "Move-Item" cmdlet moves an item, including its properties, contents, and child items, from one location to another location. For example, it can move a file or subdirectory from one directory to another or move a registry subkey from one key to another. When you move an item, it is added to the new location and deleted from its original location.
The "Move-Item" cmdlet requires 2 minimum parameters:
The example commands below shows how to use the "Move-Item" cmdlet to move a file:
PS C:\fyicenter> # Moving a directory
PS C:\fyicenter> Move-Item temp C:\temp
PS C:\fyicenter> # Moving a file
PS C:\fyicenter> Move-Item C:\temp\temp\temp.txt C:\temp
PS C:\fyicenter> dir C:\temp\temp*
Directory: C:\temp
Mode LastWriteTime Length Name
---- ------------- ------ ----
d---- 5/1/2016 7:11 PM temp
-a--- 5/1/2016 7:12 PM 16 temp.log
⇒ Copy Directory or File in Windows PowerShell
⇐ Rename Directory or File in Windows PowerShell
2016-10-24, ∼3756🔥, 0💬
Popular Posts:
What is the startup program "Persistence Module - igfxpers.exe" on my Windows 8 computer? Can I remo...
Can I remove startup application "SynTPLpr.exe - TouchPad Driver Helper Application" to speedup my c...
What is "IKE and AuthIP IPsec Keying Modules" in my Windows XP service list? And how is "IKE and Aut...
What is yinsthelper.dll - DLL File - Yahoo YInstHelper Module? yinsthelper.dll is the Yahoo YInstHel...
What is the "Server (LanmanServer)" system service on Windows Server 2012? Can I disable "Server"? "...