Skip to content

Commit

Permalink
Add support for callers using programmatic, non command line interface
Browse files Browse the repository at this point in the history
…#888 (#984)

* Prototype of exposing winget to out of proc UWP apps.

Create com exe for wrapping a winrt interface with proof of concept call to winget.

* Com server changes

Support all architectures, progress callbacks.

* Update com api proposal

* Update samples.

* Update API to match review and fix build issues

* Update for draft api.

API definitions and partial hookup.

* Implement more of the api surface

Most of the sample code now implemented.

* Update with more api implementations.

* Fix project settings.

* More api implementations and fake vector class.

* Switch to new lifetime management for oop

* Lifetime management fixes.

* Add log parameter.

* Remove manual winmd post build generation.

* API updates

* Merge changes from main branch.

* API updates

* API updates and implementation

* Add support for callers using programmatic, non command line interface #888 (#9)

* Prototype of exposing winget to out of proc UWP apps.

Create com exe for wrapping a winrt interface with proof of concept call to winget.

* Com server changes

Support all architectures, progress callbacks.

* Update com api proposal

* Update samples.

* Update API to match review and fix build issues

* Update for draft api.

API definitions and partial hookup.

* Implement more of the api surface

Most of the sample code now implemented.

* Update with more api implementations.

* Fix project settings.

* More api implementations and fake vector class.

* Switch to new lifetime management for oop

* Lifetime management fixes.

* Add log parameter.

* Remove manual winmd post build generation.

* API updates

* Merge changes from main branch.

* API updates

* API updates and implementation

* Switch from Id to Name due to rest sources

* Copyright and project updates.

* Update project name.

* Add composite changes.

* Revert refactor due to locking issue.

* Move folder again, pr comment updates

* FIx comment.

* Remove GetSourceByIdentifier

* Match target versions on new projects to existing

* Fix percentage calculation.

* Add experimental feature.

* Fix signed\unsigned warning and progress values.

* Fix comments & CompositeSearch::AvailablePackages

* fix comment.

* Update cppwinrt again

* Remove unintended packaging change

* Remove pch to try to reduce disk usage in build

* Enable WPM Client Telemetry for COM Calls and Update Projects settings for succsesful inclusion in DesktopAppInstaller solution

* Add error mapping.

* Idl changes and error catching.

* Try using PackageES for build for disk space

* Rename the experimental feature.

* Revert pipeline test.

* Drop ARM from builds

* Use details to open source instead of name

* Fix source list updatetime metadata saving

Co-authored-by: Santosh Chintalapati <[email protected]>
Co-authored-by: JohnMcPMS <[email protected]>
  • Loading branch information
3 people authored Jun 15, 2021
1 parent 3d605e0 commit 5d6b04b
Show file tree
Hide file tree
Showing 76 changed files with 3,412 additions and 156 deletions.
3 changes: 3 additions & 0 deletions .github/actions/spelling/allow.txt
Original file line number Diff line number Diff line change
Expand Up @@ -330,13 +330,15 @@ PVOID
pwa
QCol
RAII
rclsid
rdbuf
README
READONLY
READWRITE
realloc
REALTIME
Redistributable
REFCLSID
regex
regexp
removemanifest
Expand Down Expand Up @@ -459,6 +461,7 @@ tt
ttl
typedef
typename
UAC
uap
UBool
UBreak
Expand Down
26 changes: 26 additions & 0 deletions .github/actions/spelling/expect.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
abcd
abifind
adml
admx
affle
Expand All @@ -11,6 +12,7 @@ amrutha
anonymized
APARTMENTTHREADED
apfn
apicontract
apiset
appinstallertest
appname
Expand All @@ -19,8 +21,10 @@ argumentlist
ARMNT
arp
arphelper
asm
ASwitch
Atest
ATL
AType
AUrl
Aysnc
Expand Down Expand Up @@ -60,14 +64,18 @@ CLIE
cloudapp
CLSID
COINIT
combaseapi
COMGLB
commandline
compschema
Concat
contosa
contosainstaller
contoso
contractversion
count'th
countryregion
cppwinrtprocess
createmanifestmetadata
cstdint
ctc
Expand Down Expand Up @@ -127,12 +135,18 @@ hlocal
hre
HRESULTs
htm
IApp
IAttachment
IConfiguration
idl
idx
IFind
IGet
IGlobal
IHelp
IHost
IID
iinstall
IInstalled
img
IName
Expand Down Expand Up @@ -185,12 +199,14 @@ MBH
megamorf
memcpy
middleware
MIDL
minexample
minschema
MMmmbbbb
monicka
MPNS
msdownload
msdn
MSFT
msftrubengu
MSIHASH
Expand All @@ -211,10 +227,12 @@ normer
nsis
nuffing
nullopt
NX
objbase
ofile
oss
Packagedx
Packageend
pathparts
pathpaths
PCs
Expand All @@ -228,6 +246,7 @@ PMS
positionals
powertoys
productcode
pseudocode
pvk
pvm
pwabuilder
Expand All @@ -250,6 +269,7 @@ rosoft
rowids
RRF
rrr
runtimeclass
rzkzqaqjwj
SARL
schematab
Expand Down Expand Up @@ -283,6 +303,8 @@ superstring
suppy
SUSE
swervy
SYD
SYG
sysrefcomp
Tagit
temppath
Expand All @@ -305,6 +327,7 @@ uninstallation
uninstaller
uninstallprevious
uninstalls
unknwn
unparsable
UNSCOPED
UParse
Expand All @@ -316,6 +339,7 @@ userfilesetting
userprofile
USHORT
Utils
uuid
UWP
vamus
VERSI
Expand All @@ -341,7 +365,9 @@ WSL
wsv
wto
Wunused
wwinmain
WZDNCRFJ
Xaml
XPLATSTR
xsi
zy
2 changes: 1 addition & 1 deletion azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ pool:

variables:
solution: 'src/AppInstallerCLI.sln'
buildPlatform: 'x86|x64|ARM'
buildPlatform: 'x86|x64'
buildConfiguration: 'Release'
appxPackageDir: '$(build.artifactStagingDirectory)\AppxPackages\\'

Expand Down
10 changes: 10 additions & 0 deletions doc/Settings.md
Original file line number Diff line number Diff line change
Expand Up @@ -133,3 +133,13 @@ Microsoft Store App support in WinGet is currently implemented as an experimenta
"experimentalMSStore": true
},
```

### packagedAPI

Support in WinGet for packaged callers is currently implemented as an experimental feature. It allows other programs on Windows to use the Windows Package Manager. You can enable the feature as shown below.

```json
"experimentalFeatures": {
"packagedAPI": true
},
```
66 changes: 66 additions & 0 deletions src/AppInstallerCLI.sln
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ Microsoft Visual Studio Solution File, Format Version 12.00
VisualStudioVersion = 16.0.29409.12
MinimumVisualStudioVersion = 10.0.40219.1
Project("{C7167F0D-BC9F-4E6E-AFE1-012C56B48DB5}") = "AppInstallerCLIPackage", "AppInstallerCLIPackage\AppInstallerCLIPackage.wapproj", "{6AA3791A-0713-4548-A357-87A323E7AC3A}"
ProjectSection(ProjectDependencies) = postProject
{1CC41A9A-AE66-459D-9210-1E572DD7BE69} = {1CC41A9A-AE66-459D-9210-1E572DD7BE69}
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "AppInstallerCLI", "AppInstallerCLI\AppInstallerCLI.vcxproj", "{5B6F90DF-FD19-4BAE-83D9-24DAD128E777}"
EndProject
Expand Down Expand Up @@ -105,6 +108,21 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution
CodeAnalysis.ruleset = CodeAnalysis.ruleset
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Microsoft.Management.Deployment", "Microsoft.Management.Deployment\Microsoft.Management.Deployment.vcxproj", "{1CC41A9A-AE66-459D-9210-1E572DD7BE69}"
ProjectSection(ProjectDependencies) = postProject
{866C3F06-636F-4BE8-BC24-5F86ECC606A1} = {866C3F06-636F-4BE8-BC24-5F86ECC606A1}
{1C6E0108-2860-4B17-9F7E-FA5C6C1F3D3D} = {1C6E0108-2860-4B17-9F7E-FA5C6C1F3D3D}
{5EB88068-5FB9-4E69-89B2-72DBC5E068F9} = {5EB88068-5FB9-4E69-89B2-72DBC5E068F9}
{8BB94BB8-374F-4294-BCA1-C7811514A6B7} = {8BB94BB8-374F-4294-BCA1-C7811514A6B7}
{82B39FDA-E86B-4713-A873-9D56DE00247A} = {82B39FDA-E86B-4713-A873-9D56DE00247A}
{5890D6ED-7C3B-40F3-B436-B54F640D9E65} = {5890D6ED-7C3B-40F3-B436-B54F640D9E65}
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "WinGetServer", "WinGetServer\WinGetServer.vcxproj", "{2B00D362-AC92-41F3-A8D2-5B1599BDCA01}"
ProjectSection(ProjectDependencies) = postProject
{1CC41A9A-AE66-459D-9210-1E572DD7BE69} = {1CC41A9A-AE66-459D-9210-1E572DD7BE69}
EndProjectSection
EndProject
Global
GlobalSection(SharedMSBuildProjectFiles) = preSolution
ManifestSchema\ManifestSchema.vcxitems*{1622da16-914f-4f57-a259-d5169003cc8c}*SharedItemsImports = 4
Expand Down Expand Up @@ -470,6 +488,54 @@ Global
{866C3F06-636F-4BE8-BC24-5F86ECC606A1}.Release|x64.Build.0 = Release|x64
{866C3F06-636F-4BE8-BC24-5F86ECC606A1}.Release|x86.ActiveCfg = Release|Win32
{866C3F06-636F-4BE8-BC24-5F86ECC606A1}.Release|x86.Build.0 = Release|Win32
{1CC41A9A-AE66-459D-9210-1E572DD7BE69}.Debug|ARM.ActiveCfg = Debug|ARM
{1CC41A9A-AE66-459D-9210-1E572DD7BE69}.Debug|ARM.Build.0 = Debug|ARM
{1CC41A9A-AE66-459D-9210-1E572DD7BE69}.Debug|ARM64.ActiveCfg = Debug|ARM64
{1CC41A9A-AE66-459D-9210-1E572DD7BE69}.Debug|ARM64.Build.0 = Debug|ARM64
{1CC41A9A-AE66-459D-9210-1E572DD7BE69}.Debug|x64.ActiveCfg = Debug|x64
{1CC41A9A-AE66-459D-9210-1E572DD7BE69}.Debug|x64.Build.0 = Debug|x64
{1CC41A9A-AE66-459D-9210-1E572DD7BE69}.Debug|x86.ActiveCfg = Debug|Win32
{1CC41A9A-AE66-459D-9210-1E572DD7BE69}.Debug|x86.Build.0 = Debug|Win32
{1CC41A9A-AE66-459D-9210-1E572DD7BE69}.Fuzzing|ARM.ActiveCfg = Debug|ARM
{1CC41A9A-AE66-459D-9210-1E572DD7BE69}.Fuzzing|ARM.Build.0 = Debug|ARM
{1CC41A9A-AE66-459D-9210-1E572DD7BE69}.Fuzzing|ARM64.ActiveCfg = Debug|ARM64
{1CC41A9A-AE66-459D-9210-1E572DD7BE69}.Fuzzing|ARM64.Build.0 = Debug|ARM64
{1CC41A9A-AE66-459D-9210-1E572DD7BE69}.Fuzzing|x64.ActiveCfg = Debug|x64
{1CC41A9A-AE66-459D-9210-1E572DD7BE69}.Fuzzing|x64.Build.0 = Debug|x64
{1CC41A9A-AE66-459D-9210-1E572DD7BE69}.Fuzzing|x86.ActiveCfg = Debug|Win32
{1CC41A9A-AE66-459D-9210-1E572DD7BE69}.Fuzzing|x86.Build.0 = Debug|Win32
{1CC41A9A-AE66-459D-9210-1E572DD7BE69}.Release|ARM.ActiveCfg = Release|ARM
{1CC41A9A-AE66-459D-9210-1E572DD7BE69}.Release|ARM.Build.0 = Release|ARM
{1CC41A9A-AE66-459D-9210-1E572DD7BE69}.Release|ARM64.ActiveCfg = Release|ARM64
{1CC41A9A-AE66-459D-9210-1E572DD7BE69}.Release|ARM64.Build.0 = Release|ARM64
{1CC41A9A-AE66-459D-9210-1E572DD7BE69}.Release|x64.ActiveCfg = Release|x64
{1CC41A9A-AE66-459D-9210-1E572DD7BE69}.Release|x64.Build.0 = Release|x64
{1CC41A9A-AE66-459D-9210-1E572DD7BE69}.Release|x86.ActiveCfg = Release|Win32
{1CC41A9A-AE66-459D-9210-1E572DD7BE69}.Release|x86.Build.0 = Release|Win32
{2B00D362-AC92-41F3-A8D2-5B1599BDCA01}.Debug|ARM.ActiveCfg = Debug|ARM
{2B00D362-AC92-41F3-A8D2-5B1599BDCA01}.Debug|ARM.Build.0 = Debug|ARM
{2B00D362-AC92-41F3-A8D2-5B1599BDCA01}.Debug|ARM64.ActiveCfg = Debug|ARM64
{2B00D362-AC92-41F3-A8D2-5B1599BDCA01}.Debug|ARM64.Build.0 = Debug|ARM64
{2B00D362-AC92-41F3-A8D2-5B1599BDCA01}.Debug|x64.ActiveCfg = Debug|x64
{2B00D362-AC92-41F3-A8D2-5B1599BDCA01}.Debug|x64.Build.0 = Debug|x64
{2B00D362-AC92-41F3-A8D2-5B1599BDCA01}.Debug|x86.ActiveCfg = Debug|Win32
{2B00D362-AC92-41F3-A8D2-5B1599BDCA01}.Debug|x86.Build.0 = Debug|Win32
{2B00D362-AC92-41F3-A8D2-5B1599BDCA01}.Fuzzing|ARM.ActiveCfg = Debug|ARM
{2B00D362-AC92-41F3-A8D2-5B1599BDCA01}.Fuzzing|ARM.Build.0 = Debug|ARM
{2B00D362-AC92-41F3-A8D2-5B1599BDCA01}.Fuzzing|ARM64.ActiveCfg = Debug|ARM64
{2B00D362-AC92-41F3-A8D2-5B1599BDCA01}.Fuzzing|ARM64.Build.0 = Debug|ARM64
{2B00D362-AC92-41F3-A8D2-5B1599BDCA01}.Fuzzing|x64.ActiveCfg = Debug|x64
{2B00D362-AC92-41F3-A8D2-5B1599BDCA01}.Fuzzing|x64.Build.0 = Debug|x64
{2B00D362-AC92-41F3-A8D2-5B1599BDCA01}.Fuzzing|x86.ActiveCfg = Debug|Win32
{2B00D362-AC92-41F3-A8D2-5B1599BDCA01}.Fuzzing|x86.Build.0 = Debug|Win32
{2B00D362-AC92-41F3-A8D2-5B1599BDCA01}.Release|ARM.ActiveCfg = Release|ARM
{2B00D362-AC92-41F3-A8D2-5B1599BDCA01}.Release|ARM.Build.0 = Release|ARM
{2B00D362-AC92-41F3-A8D2-5B1599BDCA01}.Release|ARM64.ActiveCfg = Release|ARM64
{2B00D362-AC92-41F3-A8D2-5B1599BDCA01}.Release|ARM64.Build.0 = Release|ARM64
{2B00D362-AC92-41F3-A8D2-5B1599BDCA01}.Release|x64.ActiveCfg = Release|x64
{2B00D362-AC92-41F3-A8D2-5B1599BDCA01}.Release|x64.Build.0 = Release|x64
{2B00D362-AC92-41F3-A8D2-5B1599BDCA01}.Release|x86.ActiveCfg = Release|Win32
{2B00D362-AC92-41F3-A8D2-5B1599BDCA01}.Release|x86.Build.0 = Release|Win32
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand Down
8 changes: 4 additions & 4 deletions src/AppInstallerCLI/AppInstallerCLI.vcxproj
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.200729.8\build\native\Microsoft.Windows.CppWinRT.props" Condition="Exists('$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.200729.8\build\native\Microsoft.Windows.CppWinRT.props')" />
<Import Project="$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.210505.3\build\native\Microsoft.Windows.CppWinRT.props" Condition="Exists('$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.210505.3\build\native\Microsoft.Windows.CppWinRT.props')" />
<PropertyGroup Label="Globals">
<CppWinRTOptimized>true</CppWinRTOptimized>
<CppWinRTRootNamespaceAutoMerge>true</CppWinRTRootNamespaceAutoMerge>
Expand Down Expand Up @@ -291,13 +291,13 @@
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
<Import Project="$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.200729.8\build\native\Microsoft.Windows.CppWinRT.targets" Condition="Exists('$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.200729.8\build\native\Microsoft.Windows.CppWinRT.targets')" />
<Import Project="$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.210505.3\build\native\Microsoft.Windows.CppWinRT.targets" Condition="Exists('$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.210505.3\build\native\Microsoft.Windows.CppWinRT.targets')" />
</ImportGroup>
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
<PropertyGroup>
<ErrorText>This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
</PropertyGroup>
<Error Condition="!Exists('$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.200729.8\build\native\Microsoft.Windows.CppWinRT.props')" Text="$([System.String]::Format('$(ErrorText)', '$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.200729.8\build\native\Microsoft.Windows.CppWinRT.props'))" />
<Error Condition="!Exists('$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.200729.8\build\native\Microsoft.Windows.CppWinRT.targets')" Text="$([System.String]::Format('$(ErrorText)', '$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.200729.8\build\native\Microsoft.Windows.CppWinRT.targets'))" />
<Error Condition="!Exists('$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.210505.3\build\native\Microsoft.Windows.CppWinRT.props')" Text="$([System.String]::Format('$(ErrorText)', '$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.210505.3\build\native\Microsoft.Windows.CppWinRT.props'))" />
<Error Condition="!Exists('$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.210505.3\build\native\Microsoft.Windows.CppWinRT.targets')" Text="$([System.String]::Format('$(ErrorText)', '$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.210505.3\build\native\Microsoft.Windows.CppWinRT.targets'))" />
</Target>
</Project>
2 changes: 1 addition & 1 deletion src/AppInstallerCLI/packages.config
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="Microsoft.Windows.CppWinRT" version="2.0.200729.8" targetFramework="native" />
<package id="Microsoft.Windows.CppWinRT" version="2.0.210505.3" targetFramework="native" />
</packages>
12 changes: 6 additions & 6 deletions src/AppInstallerCLICore/AppInstallerCLICore.vcxproj
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.200729.8\build\native\Microsoft.Windows.CppWinRT.props" Condition="Exists('$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.200729.8\build\native\Microsoft.Windows.CppWinRT.props')" />
<Import Project="$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.210505.3\build\native\Microsoft.Windows.CppWinRT.props" Condition="Exists('$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.210505.3\build\native\Microsoft.Windows.CppWinRT.props')" />
<PropertyGroup Label="Globals">
<CppWinRTOptimized>true</CppWinRTOptimized>
<CppWinRTRootNamespaceAutoMerge>true</CppWinRTRootNamespaceAutoMerge>
Expand Down Expand Up @@ -334,15 +334,15 @@
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
<Import Project="$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.200729.8\build\native\Microsoft.Windows.CppWinRT.targets" Condition="Exists('$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.200729.8\build\native\Microsoft.Windows.CppWinRT.targets')" />
<Import Project="$(SolutionDir)\packages\Microsoft.Windows.ImplementationLibrary.1.0.200519.2\build\native\Microsoft.Windows.ImplementationLibrary.targets" Condition="Exists('$(SolutionDir)\packages\Microsoft.Windows.ImplementationLibrary.1.0.200519.2\build\native\Microsoft.Windows.ImplementationLibrary.targets')" />
<Import Project="$(SolutionDir)\packages\Microsoft.Windows.ImplementationLibrary.1.0.210204.1\build\native\Microsoft.Windows.ImplementationLibrary.targets" Condition="Exists('$(SolutionDir)\packages\Microsoft.Windows.ImplementationLibrary.1.0.210204.1\build\native\Microsoft.Windows.ImplementationLibrary.targets')" />
<Import Project="$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.210505.3\build\native\Microsoft.Windows.CppWinRT.targets" Condition="Exists('$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.210505.3\build\native\Microsoft.Windows.CppWinRT.targets')" />
</ImportGroup>
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
<PropertyGroup>
<ErrorText>This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
</PropertyGroup>
<Error Condition="!Exists('$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.200729.8\build\native\Microsoft.Windows.CppWinRT.props')" Text="$([System.String]::Format('$(ErrorText)', '$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.200729.8\build\native\Microsoft.Windows.CppWinRT.props'))" />
<Error Condition="!Exists('$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.200729.8\build\native\Microsoft.Windows.CppWinRT.targets')" Text="$([System.String]::Format('$(ErrorText)', '$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.200729.8\build\native\Microsoft.Windows.CppWinRT.targets'))" />
<Error Condition="!Exists('$(SolutionDir)\packages\Microsoft.Windows.ImplementationLibrary.1.0.200519.2\build\native\Microsoft.Windows.ImplementationLibrary.targets')" Text="$([System.String]::Format('$(ErrorText)', '$(SolutionDir)\packages\Microsoft.Windows.ImplementationLibrary.1.0.200519.2\build\native\Microsoft.Windows.ImplementationLibrary.targets'))" />
<Error Condition="!Exists('$(SolutionDir)\packages\Microsoft.Windows.ImplementationLibrary.1.0.210204.1\build\native\Microsoft.Windows.ImplementationLibrary.targets')" Text="$([System.String]::Format('$(ErrorText)', '$(SolutionDir)\packages\Microsoft.Windows.ImplementationLibrary.1.0.210204.1\build\native\Microsoft.Windows.ImplementationLibrary.targets'))" />
<Error Condition="!Exists('$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.210505.3\build\native\Microsoft.Windows.CppWinRT.props')" Text="$([System.String]::Format('$(ErrorText)', '$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.210505.3\build\native\Microsoft.Windows.CppWinRT.props'))" />
<Error Condition="!Exists('$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.210505.3\build\native\Microsoft.Windows.CppWinRT.targets')" Text="$([System.String]::Format('$(ErrorText)', '$(SolutionDir)\packages\Microsoft.Windows.CppWinRT.2.0.210505.3\build\native\Microsoft.Windows.CppWinRT.targets'))" />
</Target>
</Project>
4 changes: 2 additions & 2 deletions src/AppInstallerCLICore/packages.config
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="Microsoft.Windows.CppWinRT" version="2.0.200729.8" targetFramework="native" />
<package id="Microsoft.Windows.ImplementationLibrary" version="1.0.200519.2" targetFramework="native" />
<package id="Microsoft.Windows.CppWinRT" version="2.0.210505.3" targetFramework="native" />
<package id="Microsoft.Windows.ImplementationLibrary" version="1.0.210204.1" targetFramework="native" />
</packages>
1 change: 1 addition & 0 deletions src/AppInstallerCLIE2ETests/BaseCommand.cs
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ public void InitializeAllFeatures(bool status)
list = status,
upgrade = status,
uninstall = status,
packagedAPI = status,
}
};

Expand Down
1 change: 1 addition & 0 deletions src/AppInstallerCLIE2ETests/FeaturesCommand.cs
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ public void EnableExperimentalFeatures()
ConfigureFeature("experimentalArg", true);
ConfigureFeature("experimentalCmd", true);
ConfigureFeature("experimentalMSStore", true);
ConfigureFeature("packagedAPI", true);
var result = TestCommon.RunAICLICommand("features", "");
Assert.True(result.StdOut.Contains("Enabled"));
}
Expand Down
18 changes: 18 additions & 0 deletions src/AppInstallerCLIPackage/AppInstallerCLIPackage.wapproj
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,7 @@
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\AppInstallerCLI\AppInstallerCLI.vcxproj" />
<ProjectReference Include="..\WinGetServer\WinGetServer.vcxproj" />
</ItemGroup>
<Import Project="$(WapProjPath)\Microsoft.DesktopBridge.targets" />
<PropertyGroup Label="Configuration">
Expand All @@ -148,4 +149,21 @@
copy "$(TargetDir)\resources.pri" "$(TargetDir)\AppInstallerCLI\resources.pri"
</PostBuildEvent>
</PropertyGroup>
<Target Name="IncludeWinMdInPackage" AfterTargets="_ComputeAppxPackagePayload">
<PropertyGroup>
<MicrosoftManagementDeploymentPath>$(OutputPath)\..\Microsoft.Management.Deployment\Microsoft.Management.Deployment.winmd</MicrosoftManagementDeploymentPath>
<MicrosoftManagementDeploymentPath Condition="!Exists('$(MicrosoftManagementDeploymentPath)')">$(TargetDir)..\..\..\..\$(PlatformTarget)\$(Configuration)\Microsoft.Management.Deployment\Microsoft.Management.Deployment.winmd</MicrosoftManagementDeploymentPath>
<MicrosoftManagementDeploymentFileName>Microsoft.Management.Deployment.winmd</MicrosoftManagementDeploymentFileName>
</PropertyGroup>
<ItemGroup>
<MicrosoftManagementDeploymentWinmd Include="$(MicrosoftManagementDeploymentPath)" />
</ItemGroup>
<Error Condition="!Exists('$(MicrosoftManagementDeploymentPath)')" Text="$(MicrosoftManagementDeploymentPath) was not found" />
<Message Importance="normal" Condition="Exists('$(MicrosoftManagementDeploymentPath)')" Text="$(MicrosoftManagementDeploymentPath) -&gt; $(MicrosoftManagementDeploymentFileName)" />
<ItemGroup>
<AppxPackagePayload Include="@(MicrosoftManagementDeploymentWinmd)" KeepDuplicates="false">
<TargetPath>$(MicrosoftManagementDeploymentFileName)</TargetPath>
</AppxPackagePayload>
</ItemGroup>
</Target>
</Project>
Loading

0 comments on commit 5d6b04b

Please sign in to comment.