blob: a9c64452b1e838ab873f2cb4657aee0db4b098bc (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
# frozen_string_literal: true
class DependencyScanningReport
def initialize(project_path:)
report_path = project_path.join('gl-dependency-scanning-report.json')
@content = report_path.exist? ? JSON.parse(report_path.read) : {}
end
def to_h
@content
end
def to_s
JSON.pretty_generate(to_h)
end
end
|