22# Summary: Look for app's hash or url on virustotal.com
33# Help: Look for app's hash or url on virustotal.com
44#
5- # Use a single '*' for app to check all installed apps.
5+ # Use a single '*' or the '-a/--all' switch to check all installed apps.
66#
77# To use this command, you have to sign up to VirusTotal's community,
88# and get an API key. Then, tell scoop about your API key with:
2020# 2 & 4 combined
2121#
2222# Options:
23- # -a, --arch <32bit|64bit> Use the specified architecture, if the app supports it
23+ # -a, --all Check for all installed apps
2424# -s, --scan For packages where VirusTotal has no information, send download URL
2525# for analysis (and future retrieval). This requires you to configure
2626# your virustotal_api_key.
3434. " $PSScriptRoot \..\lib\install.ps1" # 'hash_for_url'
3535. " $PSScriptRoot \..\lib\depends.ps1" # 'Get-Dependency'
3636
37- $opt , $apps , $err = getopt $args ' a:snup ' @ (' arch= ' , ' scan' , ' no-depends' , ' no-update-scoop' , ' passthru' )
37+ $opt , $apps , $err = getopt $args ' asnup ' @ (' all ' , ' scan' , ' no-depends' , ' no-update-scoop' , ' passthru' )
3838if ($err ) { " scoop virustotal: $err " ; exit 1 }
3939if (! $apps ) { my_usage; exit 1 }
40- $architecture = ensure_architecture ( $opt .a + $opt .arch )
40+ $architecture = ensure_architecture
4141
4242if (is_scoop_outdated) {
4343 if ($opt.u -or $opt .' no-update-scoop' ) {
@@ -49,7 +49,7 @@ if (is_scoop_outdated) {
4949
5050$apps_param = $apps
5151
52- if ($apps_param -eq ' *' ) {
52+ if ($apps_param -eq ' *' -or $opt .a -or $opt .all ) {
5353 $apps = installed_apps $false
5454 $apps += installed_apps $true
5555}
0 commit comments