Skip to content
This repository was archived by the owner on Jan 19, 2021. It is now read-only.

Commit fc5b2ac

Browse files
Merge pull request #2081 from SharePoint/dev
May 2019 Release
2 parents bbd4739 + 4e3ae3d commit fc5b2ac

File tree

63 files changed

+1539
-944
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

63 files changed

+1539
-944
lines changed
Binary file not shown.

Binaries/SharePointPnP.Modernization.Framework.xml

+167-17
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Binary file not shown.

Binaries/release/SharePointPnP.Modernization.Framework.xml

+167-17
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

CHANGELOG.md

+39-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,45 @@ All notable changes to this project will be documented in this file.
55

66
The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/).
77

8-
## [3.8.1904.0] - unreleased
8+
## [3.10.1906.0 - June 2019 Release]
9+
10+
### Added
11+
12+
### Changed
13+
14+
### Deprecated
15+
16+
### Contributors
17+
18+
## [3.9.1905.0 - May 2019 Release]
19+
20+
### Added
21+
22+
- Added Template as a possible PromoteAs value for a Add-PnPClientSidePage and Set-PnPClientSidePage
23+
- Added -HeaderLayout and -HeaderEmphasis parameters to Set-PnPWeb
24+
- Support to specify lcid for Export-PnPTaxonomy for a particular termset
25+
- Added support in the Navigation cmdlets to manage the site footer on modern sites.
26+
- Added Invoke-PnPSPRestMethod cmdlet to execute REST requests towards a SharePoint site.
27+
- Added Enable-PnPCommSite cmdlet to convert the root site collection of a tenant into a communication site.
28+
29+
### Changed
30+
31+
- Updated documentation
32+
- ConvertTo-PnPClientSidePage: modernize the first page in case there's multiple pages matching the provided pattern (parameters identity, folder and library)
33+
- ConvertTo-PnPClientSidePage: added parameter `-PublishingTargetPageName` parameter that allows one to override the name of the target publishing page. This is needed for some pages like default.aspx
34+
- ConvertTo-PnPClientSidePage: added parameter `-SkipUrlRewrite` to prevent URL rewriting in cross site transformation scenarios
35+
- Export-PnPClientSidePageMapping: added parameter `-PublishingPage` to scope the page layout analysis to the page layout of the provided file
36+
- Export-PnPClientSidePageMapping: added parameter `-AnalyzeOOBPageLayouts` to allow analysis of OOB page layouts. By default OOB page layouts will be skipped
37+
- Fix to allow setting list property bag values on NoScript sites
38+
39+
### Deprecated
40+
- Removed support for the Template Gallery as the gallery itself is not online anymore.
41+
42+
### Contributors
43+
- Heinrich Ulbricht [heinrich-ulbricht]
44+
- Andres Mariano Gorzelany [get-itips]
45+
46+
## [3.8.1904.0]
947

1048
### Added
1149

Commands/Admin/EnableCommSite.cs

+33
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
#if !ONPREMISES
2+
using Microsoft.SharePoint.Client;
3+
using SharePointPnP.PowerShell.CmdletHelpAttributes;
4+
using SharePointPnP.PowerShell.Commands.Base;
5+
using System.Management.Automation;
6+
7+
8+
namespace SharePointPnP.PowerShell.Commands
9+
{
10+
[Cmdlet(VerbsLifecycle.Enable, "PnPCommSite")]
11+
[CmdletHelp("Enable communication site on the root site of a tenant",
12+
@"The Enable-PnPCommSite cmdlet converts the root site of a tenant to be a communication site. This action is not reversible.",
13+
Category = CmdletHelpCategory.TenantAdmin, SupportedPlatform = CmdletSupportedPlatform.Online)]
14+
[CmdletExample(
15+
Code = @"PS:> Enable-PnPCommSite",
16+
Remarks = @"This will convert the root site collection to become a communication site",
17+
SortOrder = 1)]
18+
[CmdletExample(
19+
Code = @"PS:> Enable-PnPCommSite -SiteUrl https://tenant.sharepoint.com",
20+
Remarks = @"This will convert the root site collection to become a communication site",
21+
SortOrder = 2)]
22+
public class EnableCommSite : PnPAdminCmdlet
23+
{
24+
[Parameter(Mandatory = false, HelpMessage = @"Specifies the full URL of the new site collection. It must be in a valid managed path in the company's site. For example, for company contoso, valid managed paths are https://contoso.sharepoint.com/sites and https://contoso.sharepoint.com/teams.")]
25+
public string SiteUrl;
26+
27+
protected override void ExecuteCmdlet()
28+
{
29+
Tenant.EnableCommSite(SiteUrl);
30+
}
31+
}
32+
}
33+
#endif

Commands/Admin/NewSite.cs

+5-5
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ namespace SharePointPnP.PowerShell.Commands
3535
Remarks = @"This will create a new Communications Site collection with the title 'Contoso' and the url 'https://tenant.sharepoint.com/sites/contoso'. Allows owners to invite users outside of the organization.",
3636
SortOrder = 5)]
3737
[CmdletExample(
38-
Code = @"PS:> New-PnPSite -Type CommunicationSite -Title Contoso -Url https://tenant.sharepoint.com/sites/contoso -Lcid 1044",
38+
Code = @"PS:> New-PnPSite -Type CommunicationSite -Title Contoso -Url https://tenant.sharepoint.com/sites/contoso -Lcid 1040",
3939
Remarks = @"This will create a new Communications Site collection with the title 'Contoso' and the url 'https://tenant.sharepoint.com/sites/contoso' and sets the default language to Italian.",
4040
SortOrder = 6)]
4141
[CmdletExample(
@@ -52,8 +52,8 @@ namespace SharePointPnP.PowerShell.Commands
5252
SortOrder = 9)]
5353
[CmdletAdditionalParameter(ParameterType = typeof(string), ParameterName = "Title", Mandatory = true, HelpMessage = @"Specifies the title of the new site collection", ParameterSetName = ParameterSet_COMMUNICATIONBUILTINDESIGN)]
5454
[CmdletAdditionalParameter(ParameterType = typeof(string), ParameterName = "Title", Mandatory = true, HelpMessage = @"Specifies the title of the new site collection", ParameterSetName = ParameterSet_COMMUNICATIONCUSTOMDESIGN)]
55-
[CmdletAdditionalParameter(ParameterType = typeof(string), ParameterName = "Url", Mandatory = true, HelpMessage = @"Specifies the full url of the new site collection", ParameterSetName = ParameterSet_COMMUNICATIONBUILTINDESIGN)]
56-
[CmdletAdditionalParameter(ParameterType = typeof(string), ParameterName = "Url", Mandatory = true, HelpMessage = @"Specifies the full url of the new site collection", ParameterSetName = ParameterSet_COMMUNICATIONCUSTOMDESIGN)]
55+
[CmdletAdditionalParameter(ParameterType = typeof(string), ParameterName = "Url", Mandatory = true, HelpMessage = @"Specifies the full url of the new site collection, this parameter only applies to Communications Sites", ParameterSetName = ParameterSet_COMMUNICATIONBUILTINDESIGN)]
56+
[CmdletAdditionalParameter(ParameterType = typeof(string), ParameterName = "Url", Mandatory = true, HelpMessage = @"Specifies the full url of the new site collection, this parameter only applies to Communications Sites", ParameterSetName = ParameterSet_COMMUNICATIONCUSTOMDESIGN)]
5757
[CmdletAdditionalParameter(ParameterType = typeof(string), ParameterName = "Description", Mandatory = false, HelpMessage = @"Specifies the description of the new site collection", ParameterSetName = ParameterSet_COMMUNICATIONBUILTINDESIGN)]
5858
[CmdletAdditionalParameter(ParameterType = typeof(string), ParameterName = "Description", Mandatory = false, HelpMessage = @"Specifies the description of the new site collection", ParameterSetName = ParameterSet_COMMUNICATIONCUSTOMDESIGN)]
5959
[CmdletAdditionalParameter(ParameterType = typeof(string), ParameterName = "Classification", Mandatory = false, HelpMessage = @"Specifies the classification of the new site collection", ParameterSetName = ParameterSet_COMMUNICATIONBUILTINDESIGN)]
@@ -66,7 +66,7 @@ namespace SharePointPnP.PowerShell.Commands
6666
[CmdletAdditionalParameter(ParameterType = typeof(uint), ParameterName = "Lcid", Mandatory = false, HelpMessage = @"Specifies the language of the new site collection. Defaults to the current language of the web connected to.", ParameterSetName = ParameterSet_COMMUNICATIONCUSTOMDESIGN)]
6767
[CmdletAdditionalParameter(ParameterType = typeof(uint), ParameterName = "Lcid", Mandatory = false, HelpMessage = @"Specifies the language of the new site collection. Defaults to the current language of the web connected to.", ParameterSetName = ParameterSet_TEAM)]
6868
[CmdletAdditionalParameter(ParameterType = typeof(string), ParameterName = "Title", Mandatory = true, HelpMessage = @"Specifies the title of the new site collection", ParameterSetName = ParameterSet_TEAM)]
69-
[CmdletAdditionalParameter(ParameterType = typeof(string), ParameterName = "Alias", Mandatory = true, HelpMessage = @"Specifies the alias of the new site collection which represents the part of the URL that will be assigned to the site behind 'https://tenant.sharepoint.com/sites/' or 'https://tenant.sharepoint.com/teams/' based on the managed path configuration in the SharePoint Online Admin portal", ParameterSetName = ParameterSet_TEAM)]
69+
[CmdletAdditionalParameter(ParameterType = typeof(string), ParameterName = "Alias", Mandatory = true, HelpMessage = @"Specifies the alias of the new site collection which represents the part of the URL that will be assigned to the site behind 'https://tenant.sharepoint.com/sites/' or 'https://tenant.sharepoint.com/teams/' based on the managed path configuration in the SharePoint Online Admin portal, this parameter only applies to Modern Team Sites", ParameterSetName = ParameterSet_TEAM)]
7070
[CmdletAdditionalParameter(ParameterType = typeof(string), ParameterName = "Description", Mandatory = false, HelpMessage = @"Specifies the description of the new site collection", ParameterSetName = ParameterSet_TEAM)]
7171
[CmdletAdditionalParameter(ParameterType = typeof(string), ParameterName = "Classification", Mandatory = false, HelpMessage = @"Specifies the classification of the new site collection", ParameterSetName = ParameterSet_TEAM)]
7272
[CmdletAdditionalParameter(ParameterType = typeof(string), ParameterName = "IsPublic", Mandatory = false, HelpMessage = @"Specifies if new site collection is public. Defaults to false.", ParameterSetName = ParameterSet_TEAM)]
@@ -227,4 +227,4 @@ public class TeamSiteParameters
227227
}
228228
}
229229
}
230-
#endif
230+
#endif

Commands/Base/ConnectOnline.cs

+10-12
Original file line numberDiff line numberDiff line change
@@ -245,19 +245,19 @@ public class ConnectOnline : PSCmdlet
245245
#endif
246246
public int RetryWait = 1;
247247

248-
[Parameter(Mandatory = false, ParameterSetName = ParameterSet_MAIN, HelpMessage = "The request timeout. Default is 180000")]
249-
[Parameter(Mandatory = false, ParameterSetName = ParameterSet_TOKEN, HelpMessage = "The request timeout. Default is 180000")]
250-
[Parameter(Mandatory = false, ParameterSetName = ParameterSet_WEBLOGIN, HelpMessage = "The request timeout. Default is 180000")]
248+
[Parameter(Mandatory = false, ParameterSetName = ParameterSet_MAIN, HelpMessage = "The request timeout. Default is 1800000")]
249+
[Parameter(Mandatory = false, ParameterSetName = ParameterSet_TOKEN, HelpMessage = "The request timeout. Default is 1800000")]
250+
[Parameter(Mandatory = false, ParameterSetName = ParameterSet_WEBLOGIN, HelpMessage = "The request timeout. Default is 1800000")]
251251
#if !ONPREMISES
252-
[Parameter(Mandatory = false, ParameterSetName = ParameterSet_NATIVEAAD, HelpMessage = "The request timeout. Default is 180000")]
253-
[Parameter(Mandatory = false, ParameterSetName = ParameterSet_APPONLYAAD, HelpMessage = "The request timeout. Default is 180000")]
254-
[Parameter(Mandatory = false, ParameterSetName = ParameterSet_APPONLYAADPEM, HelpMessage = "The request timeout. Default is 180000")]
255-
[Parameter(Mandatory = false, ParameterSetName = ParameterSet_SPOMANAGEMENT, HelpMessage = "The request timeout. Default is 180000")]
256-
[Parameter(Mandatory = false, ParameterSetName = ParameterSet_ACCESSTOKEN, HelpMessage = "The request timeout. Default is 180000")]
252+
[Parameter(Mandatory = false, ParameterSetName = ParameterSet_NATIVEAAD, HelpMessage = "The request timeout. Default is 1800000")]
253+
[Parameter(Mandatory = false, ParameterSetName = ParameterSet_APPONLYAAD, HelpMessage = "The request timeout. Default is 1800000")]
254+
[Parameter(Mandatory = false, ParameterSetName = ParameterSet_APPONLYAADPEM, HelpMessage = "The request timeout. Default is 1800000")]
255+
[Parameter(Mandatory = false, ParameterSetName = ParameterSet_SPOMANAGEMENT, HelpMessage = "The request timeout. Default is 1800000")]
256+
[Parameter(Mandatory = false, ParameterSetName = ParameterSet_ACCESSTOKEN, HelpMessage = "The request timeout. Default is 1800000")]
257257
#endif
258258
#if ONPREMISES
259-
[Parameter(Mandatory = false, ParameterSetName = ParameterSet_HIGHTRUST_CERT, HelpMessage = "The request timeout. Default is 180000")]
260-
[Parameter(Mandatory = false, ParameterSetName = ParameterSet_HIGHTRUST_PFX, HelpMessage = "The request timeout. Default is 180000")]
259+
[Parameter(Mandatory = false, ParameterSetName = ParameterSet_HIGHTRUST_CERT, HelpMessage = "The request timeout. Default is 1800000")]
260+
[Parameter(Mandatory = false, ParameterSetName = ParameterSet_HIGHTRUST_PFX, HelpMessage = "The request timeout. Default is 1800000")]
261261
#endif
262262
public int RequestTimeout = 1800000;
263263

@@ -327,7 +327,6 @@ public class ConnectOnline : PSCmdlet
327327
* Invite guest users to the organization
328328
* Read and write all groups
329329
* Read and write directory data
330-
* Access the directory as you
331330
* Read and write identity providers
332331
* Access the directory as you")]
333332
public SwitchParameter PnPO365ManagementShell;
@@ -344,7 +343,6 @@ public class ConnectOnline : PSCmdlet
344343
* Invite guest users to the organization
345344
* Read and write all groups
346345
* Read and write directory data
347-
* Access the directory as you
348346
* Read and write identity providers
349347
* Access the directory as you
350348
")]

Commands/Base/EnablePowerShellTelemetry.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ protected override void ProcessRecord()
2727
var telemetryFile = System.IO.Path.Combine(userFolder, ".pnppowershelltelemetry");
2828
if (Force || ShouldContinue("Do you want to enable telemetry for PnP PowerShell?", "Confirm"))
2929
{
30-
SPOnlineConnection.CurrentConnection?.InitializeTelemetry(SPOnlineConnection.CurrentConnection.Context, Host);
30+
SPOnlineConnection.CurrentConnection?.InitializeTelemetry(SPOnlineConnection.CurrentConnection.Context, Host, SPOnlineConnection.CurrentConnection.InitializationType);
3131
System.IO.File.WriteAllText(telemetryFile, "allow");
3232
WriteObject("Telemetry enabled");
3333
}

Commands/Base/GetAzureCertificate.cs

+1-2
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,7 @@ protected override void ProcessRecord()
4646
{
4747
CertificatePath = Path.Combine(SessionState.Path.CurrentFileSystemLocation.Path, CertificatePath);
4848
}
49-
50-
var certificate = new X509Certificate2(CertificatePath, CertificatePassword, X509KeyStorageFlags.Exportable);
49+
var certificate = new X509Certificate2(CertificatePath, CertificatePassword, X509KeyStorageFlags.Exportable | X509KeyStorageFlags.MachineKeySet);
5150
var rawCert = certificate.GetRawCertData();
5251
var base64Cert = Convert.ToBase64String(rawCert);
5352
var rawCertHash = certificate.GetCertHash();

Commands/Base/GetHealthScore.cs

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66
namespace SharePointPnP.PowerShell.Commands.Base
77
{
88
[Cmdlet(VerbsCommon.Get, "PnPHealthScore")]
9-
[CmdletHelp("Retrieves the healthscore",
10-
"Retrieves the current health score value of the server which is a value between 0 and 10. Lower is better.",
9+
[CmdletHelp("Retrieves the healthscore value.",
10+
"Retrieves the current X-SharePointHealthScore value of the server, or CPU, on which your SharePoint instance runs. X-SharePointHealthScore is a value between 0 and 10, where 0 indicates the server is idle and 10 indicates the server is very busy. For more information visit https://docs.microsoft.com/office365/enterprise/diagnosing-performance-issues-with-sharepoint-online and https://docs.microsoft.com/openspecs/sharepoint_protocols/ms-wsshp/c60ddeb6-4113-4a73-9e97-26b5c3907d33.",
1111
Category = CmdletHelpCategory.Base,
1212
OutputType=typeof(int),
1313
OutputTypeDescription = "Returns a int value representing the current health score value of the server.")]

0 commit comments

Comments
 (0)