script to EXTRACT bulk folders in single command
Below is the script you can use as a windows powershell script to EXTRACT bulk folders in single command . ..
$path = "C:\Users\mschi\Desktop\youtube\rename_multiple_folders"
# Validate the path
if (-Not (Test-Path $path)) {
Write-Host "Invalid path! Please check and try again."
exit
}
# Get folder names in the same order they appear
$folderNames = Get-ChildItem -Path $path -Directory | Select-Object -ExpandProperty Name
# Output the folder names in order
$folderNames | ForEach-Object { Write-Host $_ }
# Save folder names to a file (optional)
$folderNames | Out-File "$path\folder_list.txt"
Write-Host "Folder names have been extracted and saved to folder_list.txt"