Manage Microsoft Store apps on Windows. Removing an app with this modules will deprovision the app from the online Windows image.
New in version 3007.0.
Removes Microsoft Store packages from the system. If the package is part of a bundle, the entire bundle will be removed.
This function removes the package for all users on the system. It also
deprovisions the package so that it isn't re-installed by later system
updates. To only deprovision a package and not remove it for all users, set
deprovision_only=True
.
query (str) --
The query string to use to select the packages to be removed. If the string matches multiple packages, they will all be removed. Here are some example strings:
*teams*
| Remove Microsoft Teams |*zune*
| Remove Windows Media Player and Zune Video |*zuneMusic*
| Only remove Windows Media Player |*xbox*
| Remove all xBox packages, there are 5 by default*
| Remove everything but the Microsoft Store, unless include_store=True
|Note
Use the appx.list
function to make sure your query is
returning what you expect. Then use the same query to remove
those packages
include_store (bool) -- Include the Microsoft Store in the results of the query to be
removed. Use this with caution. It is difficult to reinstall the
Microsoft Store once it has been removed with this function. Default
is False
frameworks (bool) -- Include frameworks in the results of the query to be removed.
Default is False
deprovision_only (bool) -- Only deprovision the package. The package will be removed from the
current user and added to the list of deprovisioned packages. The
package will not be re-installed in future system updates. New users
of the system will not have the package installed. However, the
package will still be installed for existing users. Default is
False
True
if successful, None
if no packages found
CommandExecutionError -- On errors encountered removing the package
CLI Example:
remove_candy_crush:
appx.absent:
- query: "*candy*"