Show package contents windows

show command (winget)

Windows Package Manager and the winget tool are in public preview and may be substantially modified before they are generally available. Microsoft makes no warranties, express or implied, with respect to the information provided here.

The show command of the winget tool displays details for the specified application, including details on the source of the application as well as the metadata associated with the application.

The show command only shows metadata that was submitted with the application. If the submitted application excludes some metadata, then the data will not be displayed.

Usage

Arguments

The following arguments are available.

Argument Description
-q,—query The query used to search for an application.
-?, —help Gets additional help on this command.

Options

The following options are available.

Option Description
-m,—manifest The path to the manifest of the application to install.
—id Filter results by ID.
—name Filter results by name.
—moniker Filter results by application moniker.
-v,—version Use the specified version. The default is the latest version.
-s,—source Find the application using the specified source.
-e,—exact Find the application using exact match.
—versions Show available versions of the application.

Multiple selections

If the query provided to winget does not result in a single application, then winget will display the results of the search. This will provide you with the additional data necessary to refine the search.

Results of show

If a single application is detected, the following data will be displayed.

Package Class

Definition

Provides information about a package.

Windows 10 requirements

Remarks

Although Package is supported in desktop apps, some members of this class are supported only in UWP app. The remarks section will indicate whether a member has any restrictions on its behavior.

Version history

Windows version SDK version Value added
1607 14393 IsOptional
1607 14393 SignatureKind
1607 14393 VerifyContentIntegrityAsync
1703 15063 GetContentGroupAsync
1703 15063 GetContentGroupsAsync
1703 15063 SetInUseAsync
1703 15063 StageContentGroupsAsync(IEnumerable)
1703 15063 StageContentGroupsAsync(IEnumerable,Boolean)
1809 17763 CheckUpdateAvailabilityAsync
1809 17763 GetAppInstallerInfo
1903 18362 EffectiveLocation
1903 18362 MutableLocation
2004 19041 EffectiveExternalLocation
2004 19041 EffectiveExternalPath
2004 19041 EffectivePath
2004 19041 GetAppListEntries
2004 19041 GetLogoAsRandomAccessStreamReference
2004 19041 InstalledPath
2004 19041 IsStub
2004 19041 MachineExternalLocation
2004 19041 MachineExternalPath
2004 19041 MutablePath
2004 19041 UserExternalLocation
2004 19041 UserExternalPath

Properties

Gets the package for the current app.

Gets the packages on which the current package depends.

Gets the description of the package.

Gets the display name of the package.

Gets the location of the machine-wide or per-user external folder specified in the package manifest for the current package, depending on how the app is installed.

Gets the location of the machine-wide or per-user external folder specified in the package manifest for the current package, depending on how the app is installed.

Gets either the location of the installed folder or the mutable folder for the installed package, depending on whether the app is declared to be mutable in its package manifest.

Gets either the path of the installed folder or the mutable folder for the installed package, depending on whether the app is declared to be mutable in its package manifest.

Gets the package identity of the current package.

Windows Phone only. Gets the date the application package was installed on the user’s phone.

Gets the date on which the application package was installed or last updated.

Gets the current package’s path in the original install folder for the current package.

Gets the current package’s path in the original install folder for the current package.

Indicates whether the package is a bundle package.

Indicates whether the package is installed in development mode.

Indicates whether other packages can declare a dependency on this package.

Indicates whether the package is optional.

Indicates whether the package is a resource package.

Gets a value that indicates whether the application in the current package is a stub application.

Gets the logo of the package.

Gets the location of the machine-wide external folder specified in the package manifest for the current package.

Gets the location of the machine-wide external folder specified in the package manifest for the current package.

Gets the current package’s path in the mutable folder for the installed package, if the app is declared to be mutable in its package manifest.

Gets the current package’s path in the mutable folder for the installed package, if the app is declared to be mutable in its package manifest.

Gets the publisher display name of the package.

How the app package is signed.

Get the current status of the package for the user.

Gets the location of the per-user external folder specified in the package manifest for the current package.

Gets the path of the per-user external folder specified in the package manifest for the current package.

Methods

The CheckUpdateAvailabilityAsync method allows developers to check for updates to the main app package listed in the .appinstaller file. It allows the developer to determine if the updates are required due to .appinstaller policy. This method currently only works for applications installed via .appinstaller files.

Returns the .appinstaller XML file location. Use this method when you need to retrieve the .appinstaller XML file location for your app. For example, this is useful if your app needs to share a URI to its associated .appinstaller file. You can optionally add arguments to the URI.

Enumerates the packaged apps on the device and returns the list synchronously. Only apps included in the current package are returned.

Enumerates the packaged apps on the device and returns the list asynchronously. Only apps included in the current package are returned.

Provides information about the package content group such as its state, name, whether it is required, and so on.

Provides information about all of the package content groups in the app and their state, name, whether they are required, and so on.

Gets the application logo of the package as a random access stream.

Windows Phone only. Returns a token that can be used to retrieve the thumbnail image associated with this application package.

Windows Phone only. Launches the specified application.

Sets whether the package is in use or not.

Put the packages in the specified content groups into the staging queue.

Put the packages in the specified content groups into the staging queue; optionally placing the content groups at the head of the queue.

Ensures that the package has not been modified or tampered with before being loaded.

Диспетчер пакетов Windows (предварительная версия) Windows Package Manager (preview)

Сейчас предоставляется общедоступная предварительная версия Диспетчера пакетов Windows и средства winget. Перед выпуском общедоступной версии в решения могут быть внесены значительные изменения. Windows Package Manager and the winget tool are in public preview and may be substantially modified before they are generally available. Майкрософт не дает никаких гарантий, явных или подразумеваемых, в отношении предоставленной здесь информации. Microsoft makes no warranties, express or implied, with respect to the information provided here.

Диспетчер пакетов Windows — это комплексное решение для управления пакетами, которое состоит из программы командной строки и набора служб для установки приложений в Windows 10. Windows Package Manager is a comprehensive package manager solution that consists of a command line tool and set of services for installing applications on Windows 10.

Диспетчер пакетов Windows для разработчиков Windows Package Manager for developers

Разработчики используют программу командной строки winget для обнаружения, установки, обновления, удаления и настройки проверенного набора приложений. Developers use the winget command line tool to discover, install, upgrade, remove and configure a curated set of applications. После установки разработчики могут получить доступ к winget с помощью терминала Windows, PowerShell или командной строки. After it is installed, developers can access winget via the Windows Terminal, PowerShell, or the Command Prompt.

Диспетчер пакетов Windows для независимых поставщиков программного обеспечения Windows Package Manager for ISVs

Независимые поставщики программного обеспечения могут использовать Диспетчер пакетов Windows в качестве канала распространения пакетов программного обеспечения, содержащих их средства и приложения. Independent Software Vendors (ISVs) can use Windows Package Manager as a distribution channel for software packages containing their tools and applications. Для отправки пакетов программного обеспечения (содержащих установщики MSIX, MSI или EXE) в Диспетчер пакетов Windows мы предоставляем на сайте GitHub репозиторий манифестов пакетов сообщества Майкрософт с открытым исходным кодом. Независимые поставщики программного обеспечения могут передавать в него манифесты пакетов, которые затем могут быть включены в Диспетчер пакетов Windows. To submit software packages (containing .msix, .msi, or .exe installers) to Windows Package Manager, we provide the open source Microsoft Community Package Manifest Repository on GitHub where ISVs can upload package manifests to have their software packages considered for inclusion with Windows Package Manager. Манифесты проверяются автоматически, однако они также могут просматриваться вручную. Manifests are automatically validated and may also be reviewed manually.

Основные сведения о диспетчерах пакетов Understanding package managers

Диспетчер пакетов — это система или набор средств, используемых для автоматизации установки, обновления, настройки и использования программного обеспечения. A package manager is a system or set of tools used to automate installing, upgrading, configuring and using software. Большинство диспетчеров пакетов предназначены для обнаружения и установки средств для разработчиков. Most package managers are designed for discovering and installing developer tools.

В идеале разработчики используют диспетчер пакетов, чтобы задать компоненты, необходимых им для разработки решений под конкретный проект. Ideally, developers use a package manager to specify the prerequisites for the tools they need to develop solutions for a given project. Затем диспетчер пакетов выполняет декларативные инструкции по установке и настройке средств. The package manager then follows the declarative instructions to install and configure the tools. Диспетчер пакетов сокращает время, затрачиваемое на подготовку среды, и помогает обеспечить установку на компьютеры одних и тех же версий пакетов. The package manager reduces the time spent getting an environment ready, and it helps ensure the same versions of packages are installed on their machine.

Диспетчеры пакетов сторонних разработчиков могут использовать репозиторий манифестов пакетов сообщества Майкрософт для пополнения своего каталога программного обеспечения. Third party package managers can leverage the Microsoft Community Package Manifest Repository to increase the size of their software catalog.

Скачивание пакета вручную Manual Package Download

В коллекции Powershell поддерживается прямое скачивание пакета с веб-сайта без использования командлетов PowerShellGet. The PowerShell Gallery supports downloading a package from the website directly, without using the PowerShellGet cmdlets. Любой пакет можно скачать в формате NuGet (файла с расширением .nupkg ), который можно копировать во внутренний репозиторий. You can download any package as a NuGet package ( .nupkg ) file, which you can then copy to an internal repository.

Скачивание пакета вручную не является заменой использования командлета Install-Module . Manual package download is not intended as a replacement for the Install-Module cmdlet. При скачивании пакета не выполняется установка модуля или сценария. Downloading the package doesn’t install the module or script. В скачанном пакете NuGet нет зависимостей. Dependencies aren’t included in the NuGet package downloaded. Следующие инструкции приводятся только в информационных целях. The following instructions are provided for reference purposes only.

Получение пакета с помощью скачивания вручную Using manual download to acquire a package

На каждой странице находится ссылка для скачивания вручную, как показано ниже. Each page has a link for Manual Download, as shown here:

Чтобы скачать пакет вручную, щелкните ссылку Скачать необработанный NUPKG-файл. To download manually, click on Download the raw nupkg file. Копия пакета копируется в папку загрузки с именем . .nupkg . A copy of the package is copied to the download folder for your browser with the name . .nupkg .

Пакет NuGet — это ZIP-архив с дополнительными файлами, содержащими сведения о содержимом пакета. A NuGet package is a ZIP archive with extra files containing information about the contents of the package. Некоторые браузеры, например Internet Explorer, автоматически заменяют расширение .nupkg на .zip . Some browsers, like Internet Explorer, automatically replace the .nupkg file extension with .zip . Чтобы развернуть пакет, при необходимости переименуйте файл .nupkg в .zip , затем извлеките его содержимое в локальную папку. To expand the package, rename the .nupkg file to .zip , if needed, then extract the contents to a local folder.

Файл пакета NuGet содержит следующие характерные для NuGet элементы , которые не являются частью исходного упакованного кода: A NuGet package file includes the following NuGet-specific elements that aren’t part of the original packaged code:

  • Папка _rels содержит файл .rels со списком зависимостей. A folder named _rels — contains a .rels file that lists the dependencies
  • Папка package содержит характерные для NuGet данные. A folder named package — contains the NuGet-specific data
  • Файл [Content_Types].xml описывает работу расширений, например PowerShellGet, с помощью NuGet. A file named [Content_Types].xml — describes how extensions like PowerShellGet work with NuGet
  • Файл .nuspec содержит основной объем метаданных. A file named .nuspec — contains the bulk of the metadata

Установка модулей PowerShell из пакета NuGet Installing PowerShell modules from a NuGet package

Результат выполнения этих инструкций отличается от результата запуска командлета Install-Module . These instructions DO NOT give the same result as running Install-Module . Эти инструкции отвечают минимальным требованиям. These instructions fulfill the minimum requirements. Они не предназначены для использования в качестве замены Install-Module . They aren’t intended to be a replacement for Install-Module . Некоторые шаги, выполняемые командлетом Install-Module , не указаны. Some steps performed by Install-Module aren’t included.

Проще всего удалить характерные для NuGet элементы из папки. The easiest approach is to remove the NuGet-specific elements from the folder. При удалении элементов код PowerShell, созданный автором пакета, остается без изменений. Removing the elements leaves the PowerShell code created by the package author. Список элементов, относящихся к NuGet, см. в разделе о скачивании пакета вручную. For the list of NuGet-specific elements, see Using manual download to acquire a package.

Для этого необходимо выполнить следующие шаги: The steps are as follows:

  1. Разблокируйте скачанный из Интернета файл пакета NuGet ( .nupkg ), например с помощью командлета Unblock-File -Path C:\Downloads\module.nupkg . Unblock the Internet-downloaded NuGet package ( .nupkg ) file, for example using Unblock-File -Path C:\Downloads\module.nupkg cmdlet.
  2. Извлечь содержимое пакета NuGet в локальную папку. Extract the contents of the NuGet package to a local folder.
  3. Удалить характерные для NuGet элементы из папки. Delete the NuGet-specific elements from the folder.
  4. Переименовать папку. Rename the folder. По умолчанию используется имя папки . . The default folder name is usually . . Номер версии может содержать -prerelease , если модуль помечен как предварительная версия. The version can include -prerelease if the module is tagged as a prerelease version. Задать для папки имя модуля. Rename the folder to just the module name. Например, azurerm.storage.5.0.4-preview преобразуется в azurerm.storage . For example, azurerm.storage.5.0.4-preview becomes azurerm.storage .
  5. Скопируйте папку в одну из папок в $env:PSModulePath value . Copy the folder to one of the folders in the $env:PSModulePath value . $env:PSModulePath — это набор разделенных точками с запятой путей, в которых оболочка PowerShell должна искать модули. $env:PSModulePath is a semicolon-delimited set of paths in which PowerShell should look for modules.

При скачивании вручную не включаются зависимости, необходимые для модуля. The manual download doesn’t include any dependencies required by the module. Если у пакета есть зависимости, они должны быть установлены в системе для правильной работы этого модуля. If the package has dependencies, they must be installed on the system for this module to work correctly. В коллекции PowerShell отображаются все зависимости, необходимые для пакета. The PowerShell Gallery shows all dependencies required by the package.

Установка сценариев PowerShell из пакета NuGet Installing PowerShell scripts from a NuGet package

Результат выполнения этих инструкций отличается от результата запуска командлета Install-Script . These instructions DO NOT give the same result as running Install-Script . Эти инструкции отвечают минимальным требованиям. These instructions fulfill the minimum requirements. Они не предназначены для использования в качестве замены Install-Script . They aren’t intended to be a replacement for Install-Script .

Самым простым способом является извлечение пакета NuGet и использование сценария напрямую. The easiest approach is to extract the NuGet package, then use the script directly.

Для этого необходимо выполнить следующие шаги: The steps are as follows:

  1. Разблокируйте скачанный из Интернета файл пакета NuGet ( .nupkg ), например с помощью командлета Unblock-File -Path C:\Downloads\package.nupkg . Unblock the Internet-downloaded NuGet package ( .nupkg ) file, for example using Unblock-File -Path C:\Downloads\package.nupkg cmdlet.
  2. Извлечь содержимое пакета NuGet в локальную папку. Extract the contents of the NuGet package.
  3. Файл .PS1 в папке можно использовать прямо из этого расположения. The .PS1 file in the folder can be used directly from this location.
  4. Можно удалить характерные для NuGet элементы в папке. You may delete the NuGet-specific elements in the folder.

Список элементов, относящихся к NuGet, см. в разделе о скачивании пакета вручную. For the list of NuGet-specific elements, see Using manual download to acquire a package.

При скачивании вручную не включаются зависимости, необходимые для модуля. The manual download doesn’t include any dependencies required by the module. Если у пакета есть зависимости, они должны быть установлены в системе для правильной работы этого модуля. If the package has dependencies, they must be installed on the system for this module to work correctly. В коллекции PowerShell отображаются все зависимости, необходимые для пакета. The PowerShell Gallery shows all dependencies required by the package.

Читайте также:  Zabbix performance counter windows
Оцените статью