From 283c83f3d11421c5288aabd7ae8c2a067eec080e Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Wed, 10 Jan 2024 19:57:45 +0900 Subject: [PATCH] Layout/LeadingCommentSpace-20240109233322 (#15) * :police_car: regenerate rubocop todo * :police_car: Layout/LeadingCommentSpace * :police_car: regenerate rubocop todo --------- Co-authored-by: Rubocop Challenger --- .rubocop_todo.yml | 25 +++++++++---------------- lib/excel_templating/renderer.rb | 4 ++-- 2 files changed, 11 insertions(+), 18 deletions(-) diff --git a/.rubocop_todo.yml b/.rubocop_todo.yml index af74414..6301d4f 100644 --- a/.rubocop_todo.yml +++ b/.rubocop_todo.yml @@ -1,19 +1,11 @@ # This configuration was generated by # `rubocop --auto-gen-config --exclude-limit 180` -# on 2024-01-02 23:33:29 UTC using RuboCop version 1.59.0. +# on 2024-01-09 23:33:33 UTC using RuboCop version 1.59.0. # The point is for the user to remove these configuration records # one by one as the offenses are removed from the code base. # Note that changes in the inspected code, or installation of new # versions of RuboCop, may require this file to be generated again. -# Offense count: 1 -# This cop supports safe autocorrection (--autocorrect). -# Configuration parameters: TreatCommentsAsGroupSeparators, ConsiderPunctuation, Include. -# Include: **/*.gemfile, **/Gemfile, **/gems.rb -Bundler/OrderedGems: - Exclude: - - 'Gemfile' - # Offense count: 1 # This cop supports safe autocorrection (--autocorrect). # Configuration parameters: Severity, Include. @@ -127,13 +119,6 @@ Layout/IndentationWidth: Exclude: - 'lib/excel_templating/excel_abstraction/work_book.rb' -# Offense count: 2 -# This cop supports safe autocorrection (--autocorrect). -# Configuration parameters: AllowDoxygenCommentStyle, AllowGemfileRubyComment. -Layout/LeadingCommentSpace: - Exclude: - - 'lib/excel_templating/renderer.rb' - # Offense count: 1 # This cop supports safe autocorrection (--autocorrect). # Configuration parameters: EnforcedStyle, IndentationWidth. @@ -217,6 +202,14 @@ Layout/SpaceInsideReferenceBrackets: Exclude: - 'lib/excel_templating/renderer.rb' +# Offense count: 1 +# This cop supports safe autocorrection (--autocorrect). +# Configuration parameters: EnforcedStyle. +# SupportedStyles: final_newline, final_blank_line +Layout/TrailingEmptyLines: + Exclude: + - 'Gemfile' + # Offense count: 1 # This cop supports safe autocorrection (--autocorrect). # Configuration parameters: AllowInHeredoc. diff --git a/lib/excel_templating/renderer.rb b/lib/excel_templating/renderer.rb index 4d3b87d..5f5d54d 100644 --- a/lib/excel_templating/renderer.rb +++ b/lib/excel_templating/renderer.rb @@ -227,8 +227,8 @@ def whole_cell_template?(template) def add_validation(sheet, row_number, column_number) raise ArgumentError, "No :data_sources defined for validation!" unless data_source_registry source = sheet.validation_source_name(row_number, column_number) - #Use current_row and current_col here because row_number and column_number refer to the template - #sheet and we want to write a reference to the cell we just wrote + # Use current_row and current_col here because row_number and column_number refer to the template + # sheet and we want to write a reference to the cell we just wrote active_sheet.data_validation absolute_reference(current_row + 1, current_col), registry_renderer.absolute_reference_for(source) end