You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
set +e # Don't exit if finding version fails - handle gracefully
81
+
fuzzy_version="$(apt-cache madison ${package_name}| awk -F"|"'{print $2}'| sed -e 's/^[ \t]*//'| grep -E -m 1 "${version_regex}")"
82
+
set -e
83
+
if [ -z"${fuzzy_version}" ];then
84
+
echo"(!) No full or partial for package \"${package_name}\" match found in apt-cache for \"${requested_version}\" on OS ${ID}${VERSION_CODENAME} (${architecture})."
85
+
86
+
if$exit_on_no_match;then
87
+
echo"Available versions:"
88
+
apt-cache madison ${package_name}| awk -F"|"'{print $2}'| grep -oP '^(.+:)?\K.+'
89
+
exit 1 # Fail entire script
90
+
else
91
+
echo"Continuing to fallback method (if available)"
92
+
return 1;
93
+
fi
94
+
fi
95
+
96
+
# Globally assign fuzzy_version to this value
97
+
# Use this value as the return value of this function
# Relevant documentation for CODEOWNERS file: https://docs.github.com/en/github/creating-cloning-and-archiving-repositories/about-code-owners
2
+
3
+
# All files in this repo are owned by ose-component-detection-maintainers team.
4
+
5
+
# Reviewers are then assigned round-robin style: https://docs.github.com/en/github/setting-up-and-managing-organizations-and-teams/managing-code-review-assignment-for-your-team
Thanks for taking the time to fill out this bug report!
12
+
- type: input
13
+
id: summary
14
+
attributes:
15
+
label: Describe the bug
16
+
description: A clear and concise description of what the bug is.
17
+
- type: textarea
18
+
id: reproduce
19
+
attributes:
20
+
label: Steps To Reproduce
21
+
description: Contents of folder being scanned - minimal data to reproduce the issue is preferred. Alternatively, you can provide a link to a public github repo or gist. You can also attach files to this issue.
22
+
placeholder: Tell us what you see!
23
+
validations:
24
+
required: true
25
+
- type: input
26
+
id: version
27
+
attributes:
28
+
label: Which version of the tool was used?
29
+
description: The version of the binaries or package, or a git commit hash from the branch if you're using the sources in this repo.
30
+
- type: input
31
+
id: cli
32
+
attributes:
33
+
label: Provide the full command line input that you used to invoke the tool.
34
+
- type: textarea
35
+
id: logs
36
+
attributes:
37
+
label: Steps To Reproduce
38
+
description: 'These files are created by the tool and will provide valuable information: GovCompDisc_Log_{timestamp}.log, ScanManifest_{timestamp}.json, ScanTelemetry_{timestamp}.json You can usually find these in the %TEMP% location, or redirect them with the --Output parameter.'
0 commit comments