Petite nouvelle à powershell. J'essaye de localiser une commande de type get-childitem qui fonctionnera sur un site ftp.Powershell, ftp, get-childitem
Voici quelques pseudo-code:
$target = "c:\file.txt"
$username = "username"
$password = "password"
$ftp = "ftp://$username:[email protected]"
$webclient = New-Object System.Net.WebClient
$uri = New-Object System.Uri($ftp)
#below is the code that does not work, get-childitem needs a local path
$name = get-childitem -path $ftp
Le rendez-vous childitem fonctionne uniquement avec un chemin d'accès local. Est-ce que quelqu'un sait comment je pourrais accéder aux noms de fichiers de cette manière quand sur un site ftp?
Merci
Les réponses ici pourraient être utiles http://stackoverflow.com/questions/265339 – Shaji