Get-PnPSiteTemplate and Include folders/files

Copper Contributor

I have a SharePoint site I am using as a template with 19 Document Libraries and folder structures contained inside each library. The Get-PnPSiteTemplate contains the Libraries but not the folders inside. Is there a way to get the folders and files inside the libraries?

 

1 Reply
It isn't possible to get the contents of a library as part of the site template. You will need to create the folders seperately. Try using Add-PnPFolder
https://docs.microsoft.com/en-us/powershell/module/sharepoint-pnp/add-pnpfolder?view=sharepoint-ps