Skip to content

Commit

Permalink
Add support for Go binary package scanning
Browse files Browse the repository at this point in the history
Reference: aboutcode-org/go-inspector#15
Reference: aboutcode-org/go-inspector#13
Signed-off-by: Philippe Ombredanne <pombredanne@nexb.com>
  • Loading branch information
pombredanne committed Aug 15, 2024
1 parent 2b09be1 commit 74b7278
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 0 deletions.
1 change: 1 addition & 0 deletions requirements-linux.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
packagedcode-msitools==0.101.210706
regipy==3.1.0
rpm-inspector-rpm==4.16.1.3.210404
go-inspector
1 change: 1 addition & 0 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,7 @@ packages =
rpm_inspector_rpm >= 4.16.1.3; platform_system == 'Linux'
regipy >= 3.1.0; platform_system == 'Linux'
packagedcode_msitools >= 0.101.210706; platform_system == 'Linux'
go-inspector ; platform_system == 'Linux'


[options.entry_points]
Expand Down
6 changes: 6 additions & 0 deletions src/packagedcode/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -247,6 +247,12 @@
win_reg.InstalledProgramFromDockerUtilityvmSoftwareHandler,
]

try:
from go_inspector.binary import get_go_binary_handler
APPLICATION_PACKAGE_DATAFILE_HANDLERS.append(get_go_binary_handler())
except ImportError:
pass

ALL_DATAFILE_HANDLERS = (
APPLICATION_PACKAGE_DATAFILE_HANDLERS + [
p for p in SYSTEM_PACKAGE_DATAFILE_HANDLERS
Expand Down

0 comments on commit 74b7278

Please sign in to comment.