Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updating NuGet packages and removing no longer used ones #4417

Open
wants to merge 38 commits into
base: dev
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
38 commits
Select commit Hold shift + click to select a range
eb35e13
Updated NuGet packages, removed AngleSharp and Microsoft Graph SDK
KoenZomers Oct 11, 2024
bbe8193
Removed Newtonsoft JSON
KoenZomers Oct 11, 2024
33f47fd
Removed PowerShellStandard.Library
KoenZomers Oct 11, 2024
730ecd0
Removed System.Reflection.Emit
KoenZomers Oct 11, 2024
e249d1e
Removed System.Runtime.Loader
KoenZomers Oct 11, 2024
cea76c5
Removed System.Text.Encodings.Web
KoenZomers Oct 11, 2024
e9d3dfb
Removed System.Security.Cryptography.ProtectedData
KoenZomers Oct 11, 2024
84443aa
Removed System.Security.Cryptography.OpenSsl
KoenZomers Oct 11, 2024
4761514
Removed System.IdentityModel.Tokens.Jwt
KoenZomers Oct 11, 2024
6cece4a
Removed System.Configuration.ConfigurationManager
KoenZomers Oct 11, 2024
1b0cab3
Removed System.Text.Json
KoenZomers Oct 11, 2024
4b58c19
Removed Microsoft.IdentityModel.JsonWebTokens
KoenZomers Oct 11, 2024
38ebde6
Removed Microsoft.Extensions.Caching.Memory
KoenZomers Oct 11, 2024
7e94875
Removed Microsoft.Extensions.DependencyInjection
KoenZomers Oct 11, 2024
99d569a
Removed Microsoft.Extensions.Http
KoenZomers Oct 11, 2024
d58c465
Removed Microsoft.Identity.Client
KoenZomers Oct 11, 2024
96d094b
Removed Microsoft.Identity.Client.Broker
KoenZomers Oct 11, 2024
cdb0581
Removing no longer used Graph usings
KoenZomers Oct 11, 2024
ee17208
Updated NuGet packages, removed AngleSharp and Microsoft Graph SDK
KoenZomers Oct 11, 2024
71c1ac1
Removed Newtonsoft JSON
KoenZomers Oct 11, 2024
5f637e1
Removed PowerShellStandard.Library
KoenZomers Oct 11, 2024
8e3dc6d
Removed System.Reflection.Emit
KoenZomers Oct 11, 2024
a477413
Removed System.Runtime.Loader
KoenZomers Oct 11, 2024
f4d6d6a
Removed System.Text.Encodings.Web
KoenZomers Oct 11, 2024
ed68453
Removed System.Security.Cryptography.ProtectedData
KoenZomers Oct 11, 2024
edb5b5f
Removed System.Security.Cryptography.OpenSsl
KoenZomers Oct 11, 2024
c20d86a
Removed System.IdentityModel.Tokens.Jwt
KoenZomers Oct 11, 2024
09b194a
Removed System.Configuration.ConfigurationManager
KoenZomers Oct 11, 2024
8af183e
Removed System.Text.Json
KoenZomers Oct 11, 2024
7232dd1
Removed Microsoft.IdentityModel.JsonWebTokens
KoenZomers Oct 11, 2024
6ffc5b8
Removed Microsoft.Extensions.Caching.Memory
KoenZomers Oct 11, 2024
c4a07f8
Removed Microsoft.Extensions.DependencyInjection
KoenZomers Oct 11, 2024
73c65eb
Removed Microsoft.Extensions.Http
KoenZomers Oct 11, 2024
f8a0e09
Removed Microsoft.Identity.Client
KoenZomers Oct 11, 2024
a97016b
Removed Microsoft.Identity.Client.Broker
KoenZomers Oct 11, 2024
80679ad
Removing no longer used Graph usings
KoenZomers Oct 11, 2024
a7d9fd5
Merge branch 'UpdateNuGetPackages' of https://github.com/KoenZomers/p…
KoenZomers Oct 17, 2024
2e31009
Merge branch 'dev' into UpdateNuGetPackages
KoenZomers Oct 22, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions src/ALC/ALC.sln
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.5.002.0
MinimumVisualStudioVersion = 10.0.40219.1
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "PnP.PowerShell.ALC", "PnP.PowerShell.ALC.csproj", "{0BFB8F61-512F-405A-BC8A-7D2C804A5963}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{0BFB8F61-512F-405A-BC8A-7D2C804A5963}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{0BFB8F61-512F-405A-BC8A-7D2C804A5963}.Debug|Any CPU.Build.0 = Debug|Any CPU
{0BFB8F61-512F-405A-BC8A-7D2C804A5963}.Release|Any CPU.ActiveCfg = Release|Any CPU
{0BFB8F61-512F-405A-BC8A-7D2C804A5963}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {B34EA9CD-BE09-4B3E-ADF7-CC08EB6BDA39}
EndGlobalSection
EndGlobal
2 changes: 1 addition & 1 deletion src/ALC/PnP.PowerShell.ALC.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.ApplicationInsights" Version="2.21.0" />
<PackageReference Include="Microsoft.ApplicationInsights" Version="2.22.0" />
</ItemGroup>

</Project>
4 changes: 1 addition & 3 deletions src/Commands/Base/ConnectOnline.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
using Microsoft.Graph;
using Microsoft.SharePoint.Client;
using Microsoft.SharePoint.Client;
using PnP.Framework;
using PnP.PowerShell.Commands.Apps;
using PnP.PowerShell.Commands.Base.PipeBinds;
using PnP.PowerShell.Commands.Enums;
using PnP.PowerShell.Commands.Model;
Expand Down
31 changes: 1 addition & 30 deletions src/Commands/Base/PnPGraphCmdlet.cs
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
using Microsoft.Graph;
using Microsoft.SharePoint.Client;
using Microsoft.SharePoint.Client;
using PnP.Core.Services;
using System.Management.Automation;
using System.Net.Http.Headers;
using System.Threading.Tasks;

namespace PnP.PowerShell.Commands.Base
{
Expand All @@ -19,8 +16,6 @@ public abstract class PnPGraphCmdlet : PnPConnectedCmdlet

public PnPContext PnPContext => Connection?.PnPContext;

private GraphServiceClient serviceClient;

protected override void BeginProcessing()
{
base.BeginProcessing();
Expand All @@ -40,29 +35,5 @@ protected override void BeginProcessing()
/// Returns an Access Token for the Microsoft Graph API, if available, otherwise NULL
/// </summary>
public string AccessToken => TokenHandler.GetAccessToken(this, $"https://{Connection.GraphEndPoint}/.default", Connection);

internal GraphServiceClient ServiceClient
{
get
{
if (serviceClient == null)
{
var baseUrl = $"https://{Connection.GraphEndPoint}/v1.0";
serviceClient = new GraphServiceClient(baseUrl, new DelegateAuthenticationProvider(
async (requestMessage) =>
{
await Task.Run(() =>
{
if (!string.IsNullOrEmpty(AccessToken))
{
// Configure the HTTP bearer Authorization Header
requestMessage.Headers.Authorization = new AuthenticationHeaderValue("bearer", AccessToken);
}
});
}), new HttpProvider());
}
return serviceClient;
}
}
}
}
2 changes: 1 addition & 1 deletion src/Commands/Base/PnPSharePointCmdlet.cs
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ protected string AccessToken
{
if (Connection.Context != null)
{
var settings = Microsoft.SharePoint.Client.InternalClientContextExtensions.GetContextSettings(Connection.Context);
Framework.Utilities.Context.ClientContextSettings settings = Microsoft.SharePoint.Client.InternalClientContextExtensions.GetContextSettings(Connection.Context);
if (settings != null)
{
var authManager = settings.AuthenticationManager;
Expand Down
28 changes: 28 additions & 0 deletions src/Commands/Enums/ClonableTeamParts.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
using System;
using System.Runtime.Serialization;

namespace PnP.PowerShell.Commands.Enums
{
/// <summary>
/// Describes which part of a team should be cloned.
/// </summary>
/// <see href="https://learn.microsoft.com/en-us/graph/api/resources/clonableteamparts?view=graph-rest-1.0">
[Flags]
public enum ClonableTeamParts
{
[EnumMember(Value = "apps")]
Apps = 1,

[EnumMember(Value = "tabs")]
Tabs = 2,

[EnumMember(Value = "settings")]
Settings = 4,

[EnumMember(Value = "channels")]
Channels = 8,

[EnumMember(Value = "members")]
Members = 0x10
}
}
28 changes: 0 additions & 28 deletions src/Commands/Model/PropertyNotRetrievedException.cs

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,12 +1,7 @@
using Microsoft.Graph;
using Microsoft.Online.SharePoint.TenantAdministration;
using Microsoft.Online.SharePoint.TenantAdministration;
using Microsoft.Online.SharePoint.TenantManagement;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.Serialization;
using System.Text;
using System.Threading.Tasks;

namespace PnP.PowerShell.Commands.Model.SharePoint
{
Expand Down
2 changes: 1 addition & 1 deletion src/Commands/Model/Teams/TeamCloneSettings.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
using System.Text.Json.Serialization;
using Microsoft.Graph;
using PnP.PowerShell.Commands.Enums;
using PnP.PowerShell.Commands.Model.Graph;

namespace PnP.PowerShell.Commands.Model.Teams
Expand Down
25 changes: 2 additions & 23 deletions src/Commands/PnP.PowerShell.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -53,13 +53,6 @@
</ItemGroup>

<ItemGroup>
<PackageReference Include="AngleSharp" Version="0.17.0" />

<PackageReference Include="Microsoft.Graph" Version="3.33.0" />
<PackageReference Include="Microsoft.Identity.Client" Version="4.66.0" />
<PackageReference Include="Microsoft.Identity.Client.Broker" Version="4.66.0" />
<PackageReference Include="System.IdentityModel.Tokens.Jwt" Version="8.1.2" />
<PackageReference Include="Microsoft.IdentityModel.JsonWebTokens" Version="8.1.2" />
<PackageReference Include="Microsoft.SharePointOnline.CSOM" Version="16.1.*" />
<PackageReference Include="PnP.Framework" Version="1.17.*-*" Condition="'$(PnPFrameworkPath)' == '' and '$(IsRelease)' != '1'" />
<PackageReference Include="PnP.Framework" Version="1.17.*-*" Condition="'$(IsRelease)' == '1'" />
Expand All @@ -81,11 +74,7 @@

<!-- <PackageReference Include="PnP.Core.Transformation.SharePoint" Version="1.6.*-*" Condition="'$(PnPCoreSdkPath)' == '' and '$(IsRelease)' != '1'" />
<PackageReference Include="PnP.Core.Transformation.SharePoint" Version="*" Condition="'$(IsRelease)' == '1'" /> -->
<PackageReference Include="PnP.Core.Transformation.SharePoint" Version="1.14.*-*" />

<PackageReference Include="PowerShellStandard.Library" Version="5.1.0" />
<PackageReference Include="System.Reflection.Emit" Version="4.7.0" />
<PackageReference Include="System.Runtime.Loader" Version="4.3.0" />
<PackageReference Include="PnP.Core.Transformation.SharePoint" Version="1.14.*-*" />
<ProjectReference Include="..\ALC\PnP.PowerShell.ALC.csproj" />

</ItemGroup>
Expand Down Expand Up @@ -135,18 +124,8 @@
</ItemGroup>

<ItemGroup Condition="'$(TargetFramework)' == 'net8.0-windows'">
<PackageReference Include="Newtonsoft.Json" Version="13.0.3" />
<PackageReference Include="Microsoft.Extensions.DependencyInjection" Version="8.0.1" />
<PackageReference Include="Microsoft.Extensions.Caching.Memory" Version="8.0.1" />
<PackageReference Include="Microsoft.Extensions.Http" Version="8.0.1" />
<PackageReference Include="System.Configuration.ConfigurationManager" Version="8.0.1" />
<PackageReference Include="System.Security.Cryptography.ProtectedData" Version="8.0.0" />
<PackageReference Include="System.Security.Cryptography.OpenSsl" Version="5.0.0" />
<PackageReference Include="System.Text.Encodings.Web" Version="8.0.0" />
<PackageReference Include="System.Management.Automation" Version="7.4.4" />
<PackageReference Include="System.Text.Json" Version="8.0.5" />
<PackageReference Include="TextCopy" Version="6.2.1" />

<PackageReference Include="TextCopy" Version="6.2.1" />
</ItemGroup>

<ItemGroup>
Expand Down
5 changes: 2 additions & 3 deletions src/Commands/Teams/CopyTeamsTeam.cs
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
using Microsoft.Graph;
using PnP.Framework.Provisioning.Model.Teams;
using PnP.Framework.Provisioning.Model.Teams;
using PnP.PowerShell.Commands.Attributes;
using PnP.PowerShell.Commands.Base;
using PnP.PowerShell.Commands.Base.PipeBinds;
using PnP.PowerShell.Commands.Enums;
using PnP.PowerShell.Commands.Model.Graph;
using PnP.PowerShell.Commands.Model.Teams;
using PnP.PowerShell.Commands.Utilities;
using PnP.PowerShell.Commands.Utilities.REST;
using System;
using System.Linq;
using System.Management.Automation;
Expand Down
Loading