Set-PnPFileCheckedIn

Checks in a file

Syntax

Set-PnPFileCheckedIn
   -Url <String>
                       [-CheckinType <CheckinType>]
                       [-Comment <String>]
                       [-Approve [<SwitchParameter>]]
                       [-Web <WebPipeBind>]
                       [-Connection <SPOnlineConnection>]

Examples

------------------EXAMPLE 1------------------

PS:>Set-PnPFileCheckedIn -Url "/Documents/Contract.docx"

Checks in the file "Contract.docx" in the "Documents" library

------------------EXAMPLE 2------------------

PS:>Set-PnPFileCheckedIn -Url "/Documents/Contract.docx" -CheckinType MinorCheckin -Comment "Smaller changes"

Checks in the file "Contract.docx" in the "Documents" library as a minor version and adds the check in comment "Smaller changes"

Parameters

-Approve

Approve file

Type:SwitchParameter
Position:Named
Accept pipeline input:False
Accept wildcard characters:False
-CheckinType

The check in type to use. Defaults to Major

Type:CheckinType
Position:Named
Accept pipeline input:False
Accept wildcard characters:False
-Comment

The check in comment

Type:String
Position:Named
Accept pipeline input:False
Accept wildcard characters:False
-Connection

Optional connection to be used by the cmdlet. Retrieve the value for this parameter by either specifying -ReturnConnection on Connect-PnPOnline or by executing Get-PnPConnection.

Type:SPOnlineConnection
Position:Named
Accept pipeline input:False
Accept wildcard characters:False
-Url

The server relative url of the file to check in

Type:String
Position:0
Accept pipeline input:True
Accept wildcard characters:False
-Web

This parameter allows you to optionally apply the cmdlet action to a subweb within the current web. In most situations this parameter is not required and you can connect to the subweb using Connect-PnPOnline instead. Specify the GUID, server relative url (i.e. /sites/team1) or web instance of the web to apply the command to. Omit this parameter to use the current web.

Type:WebPipeBind
Position:Named
Accept pipeline input:False
Accept wildcard characters:False