Skip to content

Latest commit

 

History

History
143 lines (110 loc) · 2.75 KB

Set-SFTPItem.md

File metadata and controls

143 lines (110 loc) · 2.75 KB
external help file Module Name online version schema
PoshSSH.dll-Help.xml
Posh-SSH
2.0.0

Set-SFTPItem

SYNOPSIS

Upload a specific item to a remote server though a SFTP Session.

SYNTAX

Index (Default)

Set-SFTPItem [-SessionId] <Int32[]> [-Destination] <String> [-Path] <String[]> [-Force]
 [-ProgressAction <ActionPreference>] [<CommonParameters>]

Session

Set-SFTPItem [-SFTPSession] <SftpSession[]> [-Destination] <String> [-Path] <String[]> [-Force]
 [-ProgressAction <ActionPreference>] [<CommonParameters>]

DESCRIPTION

Upload a specific item to a remote server through a SFTP Session. The item can be either a file or a folder.

EXAMPLES

Example 1

PS C:\> Set-SFTPItem -SessionId 0 -Destination /tmp -Path ./Development/dns_test.py -Force

PARAMETERS

-Destination

Remote path where to upload the item to.

Type: String
Parameter Sets: (All)
Aliases:

Required: True
Position: 2
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-Force

Overwrite item on remote host if it already pressent.

Type: SwitchParameter
Parameter Sets: (All)
Aliases:

Required: False
Position: 3
Default value: False
Accept pipeline input: False
Accept wildcard characters: False

-Path

Local path to item to upload

Type: String[]
Parameter Sets: (All)
Aliases: PSPath

Required: True
Position: 1
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-SFTPSession

Existing SFTPSession object.

Type: SftpSession[]
Parameter Sets: Session
Aliases:

Required: True
Position: 0
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-SessionId

Session Id of an existing SFTPSession.

Type: Int32[]
Parameter Sets: Index
Aliases:

Required: True
Position: 0
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-ProgressAction

{{ Fill ProgressAction Description }}

Type: ActionPreference
Parameter Sets: (All)
Aliases: proga

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.

INPUTS

System.Int32[]

SSH.SftpSession[] System.String System.String[]

OUTPUTS

System.Object

NOTES

RELATED LINKS