Skip to content

Commit

Permalink
scoop-list: info +deprecated
Browse files Browse the repository at this point in the history
  • Loading branch information
HUMORCE committed Sep 24, 2024
1 parent f14c57d commit a65c84a
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions libexec/scoop-list.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,9 @@ param($query)

. "$PSScriptRoot\..\lib\versions.ps1" # 'Select-CurrentVersion'
. "$PSScriptRoot\..\lib\manifest.ps1" # 'parse_json' 'Select-CurrentVersion' (indirectly)
. "$PSScriptRoot\..\lib\download.ps1" # 'Get-UserAgent'

$def_arch = Get-DefaultArchitecture
$defaultArchitecture = Get-DefaultArchitecture
if (-not (Get-FormatData ScoopApps)) {
Update-FormatData "$PSScriptRoot\..\supporting\formats\ScoopTypes.Format.ps1xml"
}
Expand Down Expand Up @@ -47,10 +48,11 @@ $apps | Where-Object { !$query -or ($_.name -match $query) } | ForEach-Object {
$item.Updated = $updated

$info = @()
if ((app_status $app $global).deprecated) { $info += 'Deprecated package'}
if ($global) { $info += 'Global install' }
if (failed $app $global) { $info += 'Install failed' }
if ($install_info.hold) { $info += 'Held package' }
if ($install_info.architecture -and $def_arch -ne $install_info.architecture) {
if ($install_info.architecture -and $defaultArchitecture -ne $install_info.architecture) {
$info += $install_info.architecture
}
$item.Info = $info -join ', '
Expand Down

0 comments on commit a65c84a

Please sign in to comment.