Difference between revisions of "Windows Powershell"

From rbachwiki
Jump to navigation Jump to search
(Created page with "<pre> $datecurrent = get-date -Format MM-dd-yyyy $apath = "C:\Users\Robert\Desktop\leaves" $btest = "C:\Users\Robert\Desktop\leaves\pdf-sliced" $ctest = "C:\Users\Robert\Deskt...")
 
(Replaced content with "=POWERSHELL FILEBASED OPERATIONS= = Category=")
Tag: Replaced
 
(15 intermediate revisions by the same user not shown)
Line 1: Line 1:
<pre>
=[[POWERSHELL FILEBASED OPERATIONS]]=
$datecurrent = get-date -Format MM-dd-yyyy
$apath = "C:\Users\Robert\Desktop\leaves"
$btest = "C:\Users\Robert\Desktop\leaves\pdf-sliced"
$ctest = "C:\Users\Robert\Desktop\leaves\atest"


#create directory
New-Item -ItemType directory -Path "$ctest\$datecurrent"


#open folder
=[[Windows| Category]]=
ii "$ctest\$datecurrent"
 
#copy files
Copy-Item -Path $btest\* -Destination "$ctest\$datecurrent" -Verbose
 
</pre>
 
 
[[Windows| Category]]

Latest revision as of 16:38, 13 October 2021