-
Notifications
You must be signed in to change notification settings - Fork 66
Description
Announcing
We have packaged this project into winrt. With the winrt version, we can use it in cpp/winrt and other projects. You can find the winrt version in winrt branch.
How to use it
There are two way to reference it.
- Reference to the project directly
Fork this repository and change the branch to winrt.
If your project is face to uwp, add this to your .vcproj
<ProjectReference Include="\path\to\AdvancedSharpAdbClient.WinRT.csproj">
<Project>{083cdc04-9cc2-46e4-84c2-55b645be9d50}</Project>
<SetTargetFramework>TargetFramework=uap10.0</SetTargetFramework>
</ProjectReference>If your project is face to desktop, add this to your .vcproj
<ProjectReference Include="\path\to\AdvancedSharpAdbClient.WinRT.csproj">
<Project>{083cdc04-9cc2-46e4-84c2-55b645be9d50}</Project>
<SetTargetFramework>TargetFramework=net6.0-windows10.0.17763.0</SetTargetFramework>
</ProjectReference>- Reference to the nuget package
Download AdvancedSharpAdbClient.WinRT.zip.
Unzip it into nupkgs folder of the root path of your project

Create nuget.config into the root path of your project and add
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<packageSources>
<add key="Offline Nugets" value="nupkgs" />
</packageSources>
</configuration>Open the manager of nuget and you will find it. Just install it like a normal nuget.

After that, if your project is not packaged into appx or misx, remember to create ProjectName.exe.manifest in the root of your project to register winrt class.
<?xml version="1.0" encoding="utf-8"?>
<assembly manifestVersion="1.0" xmlns="urn:schemas-microsoft-com:asm.v1">
<assemblyIdentity version="1.0.0.0" name="ProjectName"/>
<file name="WinRT.Host.dll">
<activatableClass
name="AdvancedSharpAdbClient.WinRT.AdbClient"
threadingModel="both"
xmlns="urn:schemas-microsoft-com:winrt.v1" />
<activatableClass
name="AdvancedSharpAdbClient.WinRT.AdbCommandLineClient"
threadingModel="both"
xmlns="urn:schemas-microsoft-com:winrt.v1" />
<activatableClass
name="AdvancedSharpAdbClient.WinRT.AdbServer"
threadingModel="both"
xmlns="urn:schemas-microsoft-com:winrt.v1" />
<activatableClass
name="AdvancedSharpAdbClient.WinRT.AdbServerFeatures"
threadingModel="both"
xmlns="urn:schemas-microsoft-com:winrt.v1" />
<activatableClass
name="AdvancedSharpAdbClient.WinRT.AdbSocket"
threadingModel="both"
xmlns="urn:schemas-microsoft-com:winrt.v1" />
<activatableClass
name="AdvancedSharpAdbClient.WinRT.CrossPlatformFunc"
threadingModel="both"
xmlns="urn:schemas-microsoft-com:winrt.v1" />
<activatableClass
name="AdvancedSharpAdbClient.WinRT.DateTimeHelper"
threadingModel="both"
xmlns="urn:schemas-microsoft-com:winrt.v1" />
<activatableClass
name="AdvancedSharpAdbClient.WinRT.DeviceMonitor"
threadingModel="both"
xmlns="urn:schemas-microsoft-com:winrt.v1" />
<activatableClass
name="AdvancedSharpAdbClient.WinRT.Factories"
threadingModel="both"
xmlns="urn:schemas-microsoft-com:winrt.v1" />
<activatableClass
name="AdvancedSharpAdbClient.WinRT.SyncCommandConverter"
threadingModel="both"
xmlns="urn:schemas-microsoft-com:winrt.v1" />
<activatableClass
name="AdvancedSharpAdbClient.WinRT.SyncService"
threadingModel="both"
xmlns="urn:schemas-microsoft-com:winrt.v1" />
<activatableClass
name="AdvancedSharpAdbClient.WinRT.TcpSocket"
threadingModel="both"
xmlns="urn:schemas-microsoft-com:winrt.v1" />
<activatableClass
name="AdvancedSharpAdbClient.WinRT.DeviceCommands.LinuxPath"
threadingModel="both"
xmlns="urn:schemas-microsoft-com:winrt.v1" />
<activatableClass
name="AdvancedSharpAdbClient.WinRT.DeviceCommands.PackageManager"
threadingModel="both"
xmlns="urn:schemas-microsoft-com:winrt.v1" />
<activatableClass
name="AdvancedSharpAdbClient.WinRT.Logs.LogReader"
threadingModel="both"
xmlns="urn:schemas-microsoft-com:winrt.v1" />
</file>
</assembly>