WinGet Source COM Api
WinGet Source COM API Support
This update includes the following changes:
- Implementation of WinGet COM Package Catalog Management APIs:
- PackageManager.AddPackageCatalogAsync: Allows adding a new Package Catalog repository to the Windows Package Manager access list. Administrative rights are required to execute this API..
- PackageManager.RemovePackageCatalogAsync: Enables the removal of an existing Package Catalog from the Windows Package Manager access list. Administrative rights are required to execute this API.
- By default, the 'PreserveData' field is set to false, removing both the PackageCatalog registration data and system artifacts.
- When 'PreserveData' is set to true, only the PackageCatalog registration data is removed, while system artifacts remain.
- PackageCatalogReference.RefreshPackageCatalogAsync: Allows updating an existing Package Catalog repository.
- Necessary C# WinRT Projection to invoke the above API calls from the test classes.
- PackageCatalogInterop E2E Inproc and OutOfproc Test Cases to validate:
- AddPackageCatalogAsync
- RemovePackageCatalogAsync
- RefreshPackageCatalogAsync
- Added a CallbackDispatcherSink struct that handles and dispatches progress callbacks for the scenario described above, ensuring progress is reported to the caller.
- Updated Package.appxmanifest and Microsoft.Management.Deployment.InProc.dll.manifest to include the necessary COM RuntimeClass CLSIDs related to the aforementioned APIs
How Validated:
- Compiled AppInstaller.sln
- Deployed AppInstallerCLIPackage
- Copied Microsoft.Management.Deployment.winmd next to dot.exe process that runs test cases
- Executed InProc tests locally and verified all tests pass.
related: #4170
- [x] I have signed the Contributor License Agreement.
- [x] This pull request is related to an issue.
Microsoft Reviewers: Open in CodeFlow
@check-spelling-bot Report
:red_circle: Please review
See the :open_file_folder: files view, the :scroll:action log, or :memo: job summary for details.
Unrecognized words (1)
Pacakage
Previously acknowledged words that are now absent
AKV Asn azcopy clsid cobertura notmatch Peet REINSTALLMODE sas SASURL similarissues similaritytolerance templating typeparam 🫥Some files were automatically ignored :see_no_evil:
These sample patterns would exclude them:
^src/AppInstallerCLIE2ETests/TestData/empty$
You should consider adding them to:
.github/actions/spelling/excludes.txt
File matching is via Perl regular expressions.
To check these files, more of their words need to be in the dictionary than not. You can use patterns.txt to exclude portions, add items to the dictionary (e.g. by adding them to allow.txt), or fix typos.
To accept these unrecognized words as correct and remove the previously acknowledged and now absent words and update file exclusions, you could run the following commands
... in a clone of the [email protected]:Madhusudhan-MSFT/winget-cli.git repository
on the user/masudars/WinGet_Source_COM_API branch (:information_source: how do I use this?):
curl -s -S -L 'https://raw.githubusercontent.com/check-spelling/check-spelling/v0.0.22/apply.pl' |
perl - 'https://github.com/microsoft/winget-cli/actions/runs/11333576150/attempts/1'
Warnings (1)
See the :open_file_folder: files view, the :scroll:action log, or :memo: job summary for details.
| :information_source: Warnings | Count |
|---|---|
| :information_source: binary-file | 1 |
See :information_source: Event descriptions for more information.
If the flagged items are :exploding_head: false positives
If items relate to a ...
-
binary file (or some other file you wouldn't want to check at all).
Please add a file path to the
excludes.txtfile matching the containing file.File paths are Perl 5 Regular Expressions - you can test yours before committing to verify it will match your files.
^refers to the file's path from the root of the repository, so^README\.md$would exclude README.md (on whichever branch you're using). -
well-formed pattern.
If you can write a pattern that would match it, try adding it to the
patterns.txtfile.Patterns are Perl 5 Regular Expressions - you can test yours before committing to verify it will match your lines.
Note that patterns can't match multiline strings.
@check-spelling-bot Report
:red_circle: Please review
See the :open_file_folder: files view, the :scroll:action log, or :memo: job summary for details.
Unrecognized words (1)
Packagecatalog
Previously acknowledged words that are now absent
AKV Asn azcopy clsid cobertura notmatch Peet REINSTALLMODE sas SASURL similarissues similaritytolerance templating typeparam 🫥Some files were automatically ignored :see_no_evil:
These sample patterns would exclude them:
^src/AppInstallerCLIE2ETests/TestData/empty$
You should consider adding them to:
.github/actions/spelling/excludes.txt
File matching is via Perl regular expressions.
To check these files, more of their words need to be in the dictionary than not. You can use patterns.txt to exclude portions, add items to the dictionary (e.g. by adding them to allow.txt), or fix typos.
To accept these unrecognized words as correct and remove the previously acknowledged and now absent words and update file exclusions, you could run the following commands
... in a clone of the [email protected]:Madhusudhan-MSFT/winget-cli.git repository
on the user/masudars/WinGet_Source_COM_API branch (:information_source: how do I use this?):
curl -s -S -L 'https://raw.githubusercontent.com/check-spelling/check-spelling/v0.0.22/apply.pl' |
perl - 'https://github.com/microsoft/winget-cli/actions/runs/11397995594/attempts/1'
Errors (2)
See the :open_file_folder: files view, the :scroll:action log, or :memo: job summary for details.
| :x: Errors | Count |
|---|---|
| :information_source: binary-file | 1 |
| :x: forbidden-pattern | 1 |
See :x: Event descriptions for more information.
If the flagged items are :exploding_head: false positives
If items relate to a ...
-
binary file (or some other file you wouldn't want to check at all).
Please add a file path to the
excludes.txtfile matching the containing file.File paths are Perl 5 Regular Expressions - you can test yours before committing to verify it will match your files.
^refers to the file's path from the root of the repository, so^README\.md$would exclude README.md (on whichever branch you're using). -
well-formed pattern.
If you can write a pattern that would match it, try adding it to the
patterns.txtfile.Patterns are Perl 5 Regular Expressions - you can test yours before committing to verify it will match your lines.
Note that patterns can't match multiline strings.
@check-spelling-bot Report
:red_circle: Please review
See the :open_file_folder: files view, the :scroll:action log, or :memo: job summary for details.
| :x: Errors | Count |
|---|---|
| :information_source: binary-file | 1 |
| :x: forbidden-pattern | 1 |
See :x: Event descriptions for more information.
Previously acknowledged words that are now absent
AKV Asn azcopy clsid cobertura notmatch Peet REINSTALLMODE sas SASURL similarissues similaritytolerance templating typeparam 🫥Some files were automatically ignored :see_no_evil:
These sample patterns would exclude them:
^src/AppInstallerCLIE2ETests/TestData/empty$
You should consider adding them to:
.github/actions/spelling/excludes.txt
File matching is via Perl regular expressions.
To check these files, more of their words need to be in the dictionary than not. You can use patterns.txt to exclude portions, add items to the dictionary (e.g. by adding them to allow.txt), or fix typos.
To update file exclusions, you could run the following commands
... in a clone of the [email protected]:Madhusudhan-MSFT/winget-cli.git repository
on the user/masudars/WinGet_Source_COM_API branch (:information_source: how do I use this?):
curl -s -S -L 'https://raw.githubusercontent.com/check-spelling/check-spelling/v0.0.22/apply.pl' |
perl - 'https://github.com/microsoft/winget-cli/actions/runs/11398039327/attempts/1'
If the flagged items are :exploding_head: false positives
If items relate to a ...
-
binary file (or some other file you wouldn't want to check at all).
Please add a file path to the
excludes.txtfile matching the containing file.File paths are Perl 5 Regular Expressions - you can test yours before committing to verify it will match your files.
^refers to the file's path from the root of the repository, so^README\.md$would exclude README.md (on whichever branch you're using). -
well-formed pattern.
If you can write a pattern that would match it, try adding it to the
patterns.txtfile.Patterns are Perl 5 Regular Expressions - you can test yours before committing to verify it will match your lines.
Note that patterns can't match multiline strings.
@check-spelling-bot Report
:red_circle: Please review
See the :open_file_folder: files view, the :scroll:action log, or :memo: job summary for details.
| :x: Errors | Count |
|---|---|
| :information_source: binary-file | 1 |
| :x: forbidden-pattern | 1 |
See :x: Event descriptions for more information.
Previously acknowledged words that are now absent
AKV Asn azcopy clsid cobertura notmatch Peet REINSTALLMODE sas SASURL similarissues similaritytolerance templating typeparam 🫥Some files were automatically ignored :see_no_evil:
These sample patterns would exclude them:
^src/AppInstallerCLIE2ETests/TestData/empty$
You should consider adding them to:
.github/actions/spelling/excludes.txt
File matching is via Perl regular expressions.
To check these files, more of their words need to be in the dictionary than not. You can use patterns.txt to exclude portions, add items to the dictionary (e.g. by adding them to allow.txt), or fix typos.
To update file exclusions, you could run the following commands
... in a clone of the [email protected]:Madhusudhan-MSFT/winget-cli.git repository
on the user/masudars/WinGet_Source_COM_API branch (:information_source: how do I use this?):
curl -s -S -L 'https://raw.githubusercontent.com/check-spelling/check-spelling/v0.0.22/apply.pl' |
perl - 'https://github.com/microsoft/winget-cli/actions/runs/11398790190/attempts/1'
If the flagged items are :exploding_head: false positives
If items relate to a ...
-
binary file (or some other file you wouldn't want to check at all).
Please add a file path to the
excludes.txtfile matching the containing file.File paths are Perl 5 Regular Expressions - you can test yours before committing to verify it will match your files.
^refers to the file's path from the root of the repository, so^README\.md$would exclude README.md (on whichever branch you're using). -
well-formed pattern.
If you can write a pattern that would match it, try adding it to the
patterns.txtfile.Patterns are Perl 5 Regular Expressions - you can test yours before committing to verify it will match your lines.
Note that patterns can't match multiline strings.
@check-spelling-bot Report
:red_circle: Please review
See the :open_file_folder: files view, the :scroll:action log, or :memo: job summary for details.
Unrecognized words (1)
progres
Previously acknowledged words that are now absent
AKV Asn azcopy clsid cobertura notmatch Peet REINSTALLMODE sas SASURL similarissues similaritytolerance templating typeparam 🫥Some files were automatically ignored :see_no_evil:
These sample patterns would exclude them:
^src/AppInstallerCLIE2ETests/TestData/empty$
You should consider adding them to:
.github/actions/spelling/excludes.txt
File matching is via Perl regular expressions.
To check these files, more of their words need to be in the dictionary than not. You can use patterns.txt to exclude portions, add items to the dictionary (e.g. by adding them to allow.txt), or fix typos.
To accept these unrecognized words as correct and remove the previously acknowledged and now absent words and update file exclusions, you could run the following commands
... in a clone of the [email protected]:Madhusudhan-MSFT/winget-cli.git repository
on the user/masudars/WinGet_Source_COM_API branch (:information_source: how do I use this?):
curl -s -S -L 'https://raw.githubusercontent.com/check-spelling/check-spelling/v0.0.22/apply.pl' |
perl - 'https://github.com/microsoft/winget-cli/actions/runs/11504518488/attempts/1'
Warnings (1)
See the :open_file_folder: files view, the :scroll:action log, or :memo: job summary for details.
| :information_source: Warnings | Count |
|---|---|
| :information_source: binary-file | 1 |
See :information_source: Event descriptions for more information.
If the flagged items are :exploding_head: false positives
If items relate to a ...
-
binary file (or some other file you wouldn't want to check at all).
Please add a file path to the
excludes.txtfile matching the containing file.File paths are Perl 5 Regular Expressions - you can test yours before committing to verify it will match your files.
^refers to the file's path from the root of the repository, so^README\.md$would exclude README.md (on whichever branch you're using). -
well-formed pattern.
If you can write a pattern that would match it, try adding it to the
patterns.txtfile.Patterns are Perl 5 Regular Expressions - you can test yours before committing to verify it will match your lines.
Note that patterns can't match multiline strings.
Related to:
#4170