shield_ast 1.2.1 → 1.2.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: b38d31d7f4411ba2d4de694915019f9059cf19bab67079473c4597066d5e8269
4
- data.tar.gz: 60d6255349f02a11a5c85adf5ec10b9de6019b7c9d9694d15f3101ffef838301
3
+ metadata.gz: d6c939647ea823bcc6ab0e154d45ae601348a1d6be7dd3ff5d042a2bd789141f
4
+ data.tar.gz: c9f1d745bc005ed3d7c904cf23d09e62094560ee490b3771289ec224de34437d
5
5
  SHA512:
6
- metadata.gz: afc99954084847d8c6d9e9d1348638169039d2bc08a0370d7f5d86e50ad2a6d146f0724423151f168941b909a20bf5386ec767e6cd0d03d34249e0a00290c9c5
7
- data.tar.gz: c69b120cd7847b4b2f8aca24a6f9a5ac609cd12fea9eb6f95502996b050ccb3994250588f1dc59772766a0c3334f147906b7c6c79db213c51cedbead4cb4e09d
6
+ metadata.gz: 83cfc9f81a86de10ccbaaee5950d5495afeb380d73b674438345619e954c05f5a0fcf9b402fe285af83bfc7880642103b48579ea0a898dac71a372ae9e847b34
7
+ data.tar.gz: dd36eef5cb01fb5ae39025fdae774b9fa33689f96b3feacda4671544c6c778274c4f4676633b360105968b57abcaa8873c28a40a06e304357802496b8439741c
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module ShieldAst
4
- VERSION = "1.2.1"
4
+ VERSION = "1.2.2"
5
5
  end
data/lib/shield_ast.rb CHANGED
@@ -15,9 +15,9 @@ module ShieldAst
15
15
 
16
16
  # Main class for the Shield AST command-line tool.
17
17
  class Main
18
- SCAN_DATA_FILE = File.join(Dir.pwd, "lib", "reports", "scan_data.json")
19
- REPORT_JSON_FILE = File.join(Dir.pwd, "lib", "reports", "scan_report.json")
20
- REPORT_PDF_FILE = File.join(Dir.pwd, "lib", "reports", "scan_report.pdf")
18
+ SCAN_DATA_FILE = File.join(Dir.pwd, "reports", "scan_data.json")
19
+ REPORT_JSON_FILE = File.join(Dir.pwd, "reports", "scan_report.json")
20
+ REPORT_PDF_FILE = File.join(Dir.pwd, "reports", "scan_report.pdf")
21
21
  PDF_TEMPLATE = File.join(__dir__, "reports", "templates", "pdf_report_template.rb")
22
22
 
23
23
  def self.call(args)
@@ -321,7 +321,7 @@ module ShieldAst
321
321
  severity_icon = get_severity_icon(result[:severity] || result["severity"] || result[:extra]&.[](:severity) || result["extra"]&.[]("severity"))
322
322
  message = result[:extra]&.[](:message) || result["extra"]&.[]("message") || "Unknown issue"
323
323
  title = message.split(".")[0].strip
324
- file_info = "#{File.basename(result[:path] || result["path"] || "N/A")}:#{result[:start]&.[](:line) || result["start"]&.[]("line") || "N/A"}"
324
+ file_info = "#{result[:path] || result["path"] || "N/A"}:#{result[:start]&.[](:line) || result["start"]&.[]("line") || "N/A"}"
325
325
 
326
326
  puts " #{severity_icon} #{title}"
327
327
  puts " 📁 #{file_info} | #{(result[:extra]&.[](:message) || result["extra"]&.[]("message") || "No description available")[0..80]}..."
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: shield_ast
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.1
4
+ version: 1.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jose Augusto