Skip to content

Commit

Permalink
Merge branch 'pnp:dev' into features/add-site-collection-app-catalog-…
Browse files Browse the repository at this point in the history
…fields-to-builtinfields-enum
  • Loading branch information
wilecoyotegenius authored Dec 18, 2023
2 parents 2fa0847 + ee94f52 commit 368311c
Show file tree
Hide file tree
Showing 20 changed files with 287 additions and 47 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/buildandtest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
- name: Setup .NET Core
uses: actions/setup-dotnet@v1
with:
dotnet-version: '7.0.x'
dotnet-version: '8.0.x'
include-prerelease: false
- name: Install dependencies
run: dotnet restore
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/nightlynuget_dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
- name: Setup .NET Core
uses: actions/setup-dotnet@v1
with:
dotnet-version: '7.0.x'
dotnet-version: '8.0.x'
include-prerelease: false
- name: Create and publish nuget
env:
Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# PnP Framework

**PnP Framework** is a .NET Standard 2.0 / .NET 6.0 / .NET 7.0 library targeting Microsoft 365 containing the PnP Provisioning engine and a ton of other useful extensions. This library is the cross platform successor of the [PnP-Sites-Core](https://github.com/PnP/PnP-Sites-Core) library. The original [PnP-Sites-Core](https://github.com/PnP/PnP-Sites-Core) library only works on Windows (due to the dependency on .Net Framework) and supports SharePoint on-premises and SharePoint Online, while this library will work cross platform but only supports SharePoint Online. Going forward we'll only be **actively maintaining PnP Framework**, the [PnP-Sites-Core](https://github.com/PnP/PnP-Sites-Core) library is retired and archived.
**PnP Framework** is a .NET Standard 2.0 / .NET 6.0 / .NET 7.0 / .NET 8.0 library targeting Microsoft 365 containing the PnP Provisioning engine and a ton of other useful extensions. This library is the cross platform successor of the [PnP-Sites-Core](https://github.com/PnP/PnP-Sites-Core) library. The original [PnP-Sites-Core](https://github.com/PnP/PnP-Sites-Core) library only works on Windows (due to the dependency on .Net Framework) and supports SharePoint on-premises and SharePoint Online, while this library will work cross platform but only supports SharePoint Online. Going forward we'll only be **actively maintaining PnP Framework**, the [PnP-Sites-Core](https://github.com/PnP/PnP-Sites-Core) library is retired and archived.

Next to PnP Framework that will be replacing [PnP-Sites-Core](https://github.com/PnP/PnP-Sites-Core) we're also building a brand new [PnP Core SDK](https://github.com/pnp/pnpcore) that targets modern .NET development and which will work everywhere where .NET will run. This library is the long term evolution of PnP Framework, we'll enable a phased transition from PnP Framework to [PnP Core SDK](https://github.com/pnp/pnpcore) without impacting PnP Framework users.

Expand Down Expand Up @@ -29,7 +29,7 @@ This library is open-source and community provided component with active communi
To build PnP Framework you need the following minimal components installed:

- [Visual Studio 2022](https://visualstudio.microsoft.com/vs/)
- [.NET SDK version 7.0](https://dotnet.microsoft.com/en-us/download/dotnet/7.0)
- [.NET SDK version 8.0](https://dotnet.microsoft.com/en-us/download/dotnet/8.0)

Contributions should be made against the **dev** branch of the repository.

Expand All @@ -38,4 +38,4 @@ Contributions should be made against the **dev** branch of the repository.
This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/). For more information see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) or contact [[email protected]](mailto:[email protected]) with any additional questions or comments.


<img src="https://m365-visitor-stats.azurewebsites.net/pnpframework/readme" />
<img src="https://m365-visitor-stats.azurewebsites.net/pnpframework/readme" />
3 changes: 3 additions & 0 deletions build/build-debug.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -28,15 +28,18 @@ if ($LocalPnPCore) {
$pnpCoreAssembly5 = Join-Path $PSScriptRoot -ChildPath "..\..\pnpcore\src\sdk\PnP.Core\bin\Debug\net5.0\PnP.Core.dll"
$pnpCoreAssembly6 = Join-Path $PSScriptRoot -ChildPath "..\..\pnpcore\src\sdk\PnP.Core\bin\Debug\net6.0\PnP.Core.dll"
$pnpCoreAssembly7 = Join-Path $PSScriptRoot -ChildPath "..\..\pnpcore\src\sdk\PnP.Core\bin\Debug\net7.0\PnP.Core.dll"
$pnpCoreAssembly8 = Join-Path $PSScriptRoot -ChildPath "..\..\pnpcore\src\sdk\PnP.Core\bin\Debug\net8.0\PnP.Core.dll"
$pnpCoreAssembly = [System.IO.Path]::GetFullPath($pnpCoreAssembly)
$pnpCoreAssembly5 = [System.IO.Path]::GetFullPath($pnpCoreAssembly5)
$pnpCoreAssembly6 = [System.IO.Path]::GetFullPath($pnpCoreAssembly6)
$pnpCoreAssembly7 = [System.IO.Path]::GetFullPath($pnpCoreAssembly7)
$pnpCoreAssembly8 = [System.IO.Path]::GetFullPath($pnpCoreAssembly8)
if (Test-Path $pnpCoreAssembly -PathType Leaf) {
$buildCmd += " -p:PnPCoreSdkPath=`"$pnpCoreAssembly`""
$buildCmd += " -p:PnPCoreSdkPathNet5=`"$pnpCoreAssembly5`""
$buildCmd += " -p:PnPCoreSdkPathNet6=`"$pnpCoreAssembly6`""
$buildCmd += " -p:PnPCoreSdkPathNet7=`"$pnpCoreAssembly7`""
$buildCmd += " -p:PnPCoreSdkPathNet8=`"$pnpCoreAssembly8`""
}
else {
Write-Error -Message "PnP Core Assembly path $pnpCoreAssembly not found"
Expand Down
2 changes: 1 addition & 1 deletion build/version.debug
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.13.{incremental}-nightly
1.14.{incremental}-nightly
2 changes: 1 addition & 1 deletion build/version.debug.increment
Original file line number Diff line number Diff line change
@@ -1 +1 @@
111
8
2 changes: 1 addition & 1 deletion docs/contributing/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,4 +26,4 @@ You can:

## Having problems

If you are having problems contributing, please reach out by creating an issue in the [PnP Framework GitHub Repository}(https://github.com/pnp/pnpframework/issues), it would help to ensure the quality of the documentation is good enough to help folks get started.
If you are having problems contributing, please reach out by creating an issue in the [PnP Framework GitHub Repository](https://github.com/pnp/pnpframework/issues), it would help to ensure the quality of the documentation is good enough to help folks get started.
160 changes: 160 additions & 0 deletions src/lib/.editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,160 @@
# Visual Studio generated .editorconfig file with C++ settings.
root = true

[*.{c++,cc,cpp,cppm,cxx,h,h++,hh,hpp,hxx,inl,ipp,ixx,tlh,tli}]

# Visual C++ Code Style settings

cpp_generate_documentation_comments = xml

# Visual C++ Formatting settings

cpp_indent_braces = false
cpp_indent_multi_line_relative_to = innermost_parenthesis
cpp_indent_within_parentheses = indent
cpp_indent_preserve_within_parentheses = true
cpp_indent_case_contents = true
cpp_indent_case_labels = false
cpp_indent_case_contents_when_block = false
cpp_indent_lambda_braces_when_parameter = true
cpp_indent_goto_labels = one_left
cpp_indent_preprocessor = leftmost_column
cpp_indent_access_specifiers = false
cpp_indent_namespace_contents = true
cpp_indent_preserve_comments = false
cpp_new_line_before_open_brace_namespace = ignore
cpp_new_line_before_open_brace_type = ignore
cpp_new_line_before_open_brace_function = ignore
cpp_new_line_before_open_brace_block = ignore
cpp_new_line_before_open_brace_lambda = ignore
cpp_new_line_scope_braces_on_separate_lines = false
cpp_new_line_close_brace_same_line_empty_type = false
cpp_new_line_close_brace_same_line_empty_function = false
cpp_new_line_before_catch = true
cpp_new_line_before_else = true
cpp_new_line_before_while_in_do_while = false
cpp_space_before_function_open_parenthesis = remove
cpp_space_within_parameter_list_parentheses = false
cpp_space_between_empty_parameter_list_parentheses = false
cpp_space_after_keywords_in_control_flow_statements = true
cpp_space_within_control_flow_statement_parentheses = false
cpp_space_before_lambda_open_parenthesis = false
cpp_space_within_cast_parentheses = false
cpp_space_after_cast_close_parenthesis = false
cpp_space_within_expression_parentheses = false
cpp_space_before_block_open_brace = true
cpp_space_between_empty_braces = false
cpp_space_before_initializer_list_open_brace = false
cpp_space_within_initializer_list_braces = true
cpp_space_preserve_in_initializer_list = true
cpp_space_before_open_square_bracket = false
cpp_space_within_square_brackets = false
cpp_space_before_empty_square_brackets = false
cpp_space_between_empty_square_brackets = false
cpp_space_group_square_brackets = true
cpp_space_within_lambda_brackets = false
cpp_space_between_empty_lambda_brackets = false
cpp_space_before_comma = false
cpp_space_after_comma = true
cpp_space_remove_around_member_operators = true
cpp_space_before_inheritance_colon = true
cpp_space_before_constructor_colon = true
cpp_space_remove_before_semicolon = true
cpp_space_after_semicolon = true
cpp_space_remove_around_unary_operator = true
cpp_space_around_binary_operator = insert
cpp_space_around_assignment_operator = insert
cpp_space_pointer_reference_alignment = left
cpp_space_around_ternary_operator = insert
cpp_use_unreal_engine_macro_formatting = true
cpp_wrap_preserve_blocks = one_liners

# Visual C++ Inlcude Cleanup settings

cpp_include_cleanup_add_missing_error_tag_type = suggestion
cpp_include_cleanup_remove_unused_error_tag_type = dimmed
cpp_include_cleanup_sort_after_edits = false
cpp_sort_includes_error_tag_type = none
cpp_sort_includes_priority_case_sensitive = false
cpp_sort_includes_priority_style = quoted
cpp_includes_style = default
cpp_includes_use_forward_slash = true

[*.{cs,vb}]
#### Naming styles ####

# Naming rules

dotnet_naming_rule.interface_should_be_begins_with_i.severity = suggestion
dotnet_naming_rule.interface_should_be_begins_with_i.symbols = interface
dotnet_naming_rule.interface_should_be_begins_with_i.style = begins_with_i

dotnet_naming_rule.types_should_be_pascal_case.severity = suggestion
dotnet_naming_rule.types_should_be_pascal_case.symbols = types
dotnet_naming_rule.types_should_be_pascal_case.style = pascal_case

dotnet_naming_rule.non_field_members_should_be_pascal_case.severity = suggestion
dotnet_naming_rule.non_field_members_should_be_pascal_case.symbols = non_field_members
dotnet_naming_rule.non_field_members_should_be_pascal_case.style = pascal_case

# Symbol specifications

dotnet_naming_symbols.interface.applicable_kinds = interface
dotnet_naming_symbols.interface.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected
dotnet_naming_symbols.interface.required_modifiers =

dotnet_naming_symbols.types.applicable_kinds = class, struct, interface, enum
dotnet_naming_symbols.types.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected
dotnet_naming_symbols.types.required_modifiers =

dotnet_naming_symbols.non_field_members.applicable_kinds = property, event, method
dotnet_naming_symbols.non_field_members.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected
dotnet_naming_symbols.non_field_members.required_modifiers =

# Naming styles

dotnet_naming_style.begins_with_i.required_prefix = I
dotnet_naming_style.begins_with_i.required_suffix =
dotnet_naming_style.begins_with_i.word_separator =
dotnet_naming_style.begins_with_i.capitalization = pascal_case

dotnet_naming_style.pascal_case.required_prefix =
dotnet_naming_style.pascal_case.required_suffix =
dotnet_naming_style.pascal_case.word_separator =
dotnet_naming_style.pascal_case.capitalization = pascal_case

dotnet_naming_style.pascal_case.required_prefix =
dotnet_naming_style.pascal_case.required_suffix =
dotnet_naming_style.pascal_case.word_separator =
dotnet_naming_style.pascal_case.capitalization = pascal_case
dotnet_style_operator_placement_when_wrapping = beginning_of_line
tab_width = 4
indent_size = 4
end_of_line = crlf
dotnet_style_coalesce_expression = true:suggestion
dotnet_style_null_propagation = true:suggestion
dotnet_style_prefer_is_null_check_over_reference_equality_method = true:suggestion
dotnet_style_prefer_auto_properties = true:silent
dotnet_style_object_initializer = true:suggestion
dotnet_style_prefer_collection_expression = true:suggestion
dotnet_style_collection_initializer = true:suggestion
dotnet_style_prefer_simplified_boolean_expressions = true:suggestion
dotnet_style_prefer_conditional_expression_over_assignment = true:silent

[*.cs]
csharp_indent_labels = one_less_than_current
csharp_using_directive_placement = outside_namespace:silent
csharp_prefer_simple_using_statement = false:suggestion
csharp_prefer_braces = true:silent
csharp_style_namespace_declarations = block_scoped:silent
csharp_style_prefer_method_group_conversion = true:silent
csharp_style_prefer_top_level_statements = true:silent
csharp_style_prefer_primary_constructors = true:suggestion
csharp_style_expression_bodied_methods = false:silent
csharp_style_expression_bodied_constructors = false:silent
csharp_style_expression_bodied_operators = false:silent
csharp_style_expression_bodied_properties = true:silent
csharp_style_expression_bodied_indexers = true:silent
csharp_style_expression_bodied_accessors = true:silent
csharp_style_expression_bodied_lambdas = true:silent
csharp_style_expression_bodied_local_functions = false:silent
7 changes: 6 additions & 1 deletion src/lib/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,13 @@ All notable changes to this project will be documented in this file.

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

## [Unreleased]
## [1.14.0]

### Added

- Added Stream and XML option to load Tenant template #918 [koenzomers - Koen Zomers]
- Implement adding labels to terms #934 [koskila - Antti K. Koskela]
- Support for .NET 8.0 [jansenbe - Bert Jansen]

### Changed

Expand All @@ -19,6 +21,9 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/).
- Fixed non-taxonomy default folder values cause error when generating a provisioning template #915 [JakeStanger - Jake Stanger]
- Removing the accents and unallowed characters when creating modern non group connected sites #922 [gautamdsheth - Gautam Sheth]
- Added support for users utility in the other cloud environments #924 [gautamdsheth - Gautam Sheth]
- Fixed occasional crash when setting default values #926 [JakeStanger - Jake Stanger]
- Escape apostrophe in alias before calling DirectorySession/Group method #933 [magarma - Miguel Angel García Martínez]
- Fixed unable to set column defaults on library root #947 [JakeStanger - Jake Stanger]

## [1.13.0]

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>net6.0</TargetFramework>
<TargetFramework>net8.0</TargetFramework>

<IsPackable>false</IsPackable>
<SignAssembly>true</SignAssembly>
Expand All @@ -10,11 +10,11 @@

<ItemGroup>
<PackageReference Include="AngleSharp" Version="0.17.0" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.7.1" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.8.0" />
<PackageReference Include="Moq" Version="4.15.1" />
<PackageReference Include="MSTest.TestAdapter" Version="2.1.1" />
<PackageReference Include="MSTest.TestFramework" Version="2.1.1" />
<PackageReference Include="coverlet.collector" Version="1.3.0" />
<PackageReference Include="MSTest.TestAdapter" Version="3.1.1" />
<PackageReference Include="MSTest.TestFramework" Version="3.1.1" />
<PackageReference Include="coverlet.collector" Version="6.0.0" />
</ItemGroup>

<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2515,8 +2515,8 @@ public void XMLSerializer_Deserialize_ContentTypes()
Assert.IsTrue(ct.DocumentSetTemplate.RemoveExistingContentTypes);
Assert.IsNotNull(ct.DocumentSetTemplate.AllowedContentTypes.FirstOrDefault(c => c.ContentTypeId == "0x01005D4F34E4BE7F4B6892AEBE088EDD215E"));

Assert.AreNotEqual(Guid.Empty, ct.DocumentSetTemplate.SharedFields.FirstOrDefault(c => c.Id == new Guid("B01B3DBC-4630-4ED1-B5BA-321BC7841E3D")));
Assert.AreNotEqual(Guid.Empty, ct.DocumentSetTemplate.WelcomePageFields.FirstOrDefault(c => c.Id == new Guid("23203E97-3BFE-40CB-AFB4-07AA2B86BF45")));
Assert.AreNotEqual(null, ct.DocumentSetTemplate.SharedFields.FirstOrDefault(c => c.Id == new Guid("B01B3DBC-4630-4ED1-B5BA-321BC7841E3D")));
Assert.AreNotEqual(null, ct.DocumentSetTemplate.WelcomePageFields.FirstOrDefault(c => c.Id == new Guid("23203E97-3BFE-40CB-AFB4-07AA2B86BF45")));

Assert.IsNotNull(ct.DocumentSetTemplate.DefaultDocuments);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2970,8 +2970,8 @@ public void XMLSerializer_Deserialize_ContentTypes()
Assert.IsTrue(ct.DocumentSetTemplate.RemoveExistingContentTypes);
Assert.IsNotNull(ct.DocumentSetTemplate.AllowedContentTypes.FirstOrDefault(c => c.ContentTypeId == "0x01005D4F34E4BE7F4B6892AEBE088EDD215E"));

Assert.AreNotEqual(Guid.Empty, ct.DocumentSetTemplate.SharedFields.FirstOrDefault(c => c.Id == new Guid("B01B3DBC-4630-4ED1-B5BA-321BC7841E3D")));
Assert.AreNotEqual(Guid.Empty, ct.DocumentSetTemplate.WelcomePageFields.FirstOrDefault(c => c.Id == new Guid("23203E97-3BFE-40CB-AFB4-07AA2B86BF45")));
Assert.AreNotEqual(null, ct.DocumentSetTemplate.SharedFields.FirstOrDefault(c => c.Id == new Guid("B01B3DBC-4630-4ED1-B5BA-321BC7841E3D")));
Assert.AreNotEqual(null, ct.DocumentSetTemplate.WelcomePageFields.FirstOrDefault(c => c.Id == new Guid("23203E97-3BFE-40CB-AFB4-07AA2B86BF45")));

Assert.IsNotNull(ct.DocumentSetTemplate.DefaultDocuments);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3071,8 +3071,8 @@ public void XMLSerializer_Deserialize_ContentTypes()
Assert.IsTrue(ct.DocumentSetTemplate.RemoveExistingContentTypes);
Assert.IsNotNull(ct.DocumentSetTemplate.AllowedContentTypes.FirstOrDefault(c => c.ContentTypeId == "0x01005D4F34E4BE7F4B6892AEBE088EDD215E"));

Assert.AreNotEqual(Guid.Empty, ct.DocumentSetTemplate.SharedFields.FirstOrDefault(c => c.Id == new Guid("B01B3DBC-4630-4ED1-B5BA-321BC7841E3D")));
Assert.AreNotEqual(Guid.Empty, ct.DocumentSetTemplate.WelcomePageFields.FirstOrDefault(c => c.Id == new Guid("23203E97-3BFE-40CB-AFB4-07AA2B86BF45")));
Assert.AreNotEqual(null, ct.DocumentSetTemplate.SharedFields.FirstOrDefault(c => c.Id == new Guid("B01B3DBC-4630-4ED1-B5BA-321BC7841E3D")));
Assert.AreNotEqual(null, ct.DocumentSetTemplate.WelcomePageFields.FirstOrDefault(c => c.Id == new Guid("23203E97-3BFE-40CB-AFB4-07AA2B86BF45")));

Assert.IsNotNull(ct.DocumentSetTemplate.DefaultDocuments);

Expand Down
16 changes: 8 additions & 8 deletions src/lib/PnP.Framework.Test/PnP.Framework.Test.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>net6.0</TargetFramework>
<TargetFramework>net8.0</TargetFramework>
<IsPackable>false</IsPackable>
<SignAssembly>true</SignAssembly>
<AssemblyOriginatorKeyFile>..\pnp.core.snk</AssemblyOriginatorKeyFile>
Expand Down Expand Up @@ -175,18 +175,18 @@
</ItemGroup>

<ItemGroup>
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.8.0" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.8.0" />
<PackageReference Include="Microsoft.SharePointOnline.CSOM" Version="16.1.*" />
<PackageReference Include="MSTest.TestAdapter" Version="2.1.2" />
<PackageReference Include="MSTest.TestFramework" Version="2.1.2" />
<PackageReference Include="coverlet.collector" Version="1.3.0">
<PackageReference Include="MSTest.TestAdapter" Version="3.1.1" />
<PackageReference Include="MSTest.TestFramework" Version="3.1.1" />
<PackageReference Include="coverlet.collector" Version="6.0.0">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="PrivateObjectExtensions" Version="1.4.0" />
<PackageReference Include="System.Configuration.ConfigurationManager" Version="6.0.1" />
<PackageReference Include="System.Security.Cryptography.Xml" Version="6.0.0" />
<PackageReference Include="PnP.Core" Version="1.10.*-*" Condition="'$(PnPCoreSdkPath)' == ''" />
<PackageReference Include="System.Configuration.ConfigurationManager" Version="8.0.0" />
<PackageReference Include="System.Security.Cryptography.Xml" Version="8.0.0" />
<PackageReference Include="PnP.Core" Version="1.11.*-*" Condition="'$(PnPCoreSdkPath)' == ''" />
</ItemGroup>

<ItemGroup>
Expand Down
Loading

0 comments on commit 368311c

Please sign in to comment.