From 5a6229ad7bd88c9e419dbaf6cf0cf6e1f6f34d3a Mon Sep 17 00:00:00 2001 From: hitman Date: Tue, 21 Mar 2017 18:05:42 +0530 Subject: [PATCH 1/9] add haml_lint gem --- Gemfile | 1 + 1 file changed, 1 insertion(+) diff --git a/Gemfile b/Gemfile index b1c5764f..ccfd3870 100644 --- a/Gemfile +++ b/Gemfile @@ -198,6 +198,7 @@ group :development do # to launch specs when files are modified gem 'guard-rspec', '~> 4.2.8' gem 'spring-commands-rspec' + gem 'haml_lint' # for static code analisys gem 'rubocop', require: false # as database From b55ecf93fba604eb971eb05ccc9af929cbdee61b Mon Sep 17 00:00:00 2001 From: hitman Date: Tue, 21 Mar 2017 18:06:08 +0530 Subject: [PATCH 2/9] add haml-lint.yml --- .haml-lint.yml | 116 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 116 insertions(+) create mode 100644 .haml-lint.yml diff --git a/.haml-lint.yml b/.haml-lint.yml new file mode 100644 index 00000000..86047884 --- /dev/null +++ b/.haml-lint.yml @@ -0,0 +1,116 @@ +linters: + AlignmentTabs: + enabled: true + + AltText: + enabled: true + + ClassAttributeWithStaticValue: + enabled: true + + ClassesBeforeIds: + enabled: true + + ConsecutiveComments: + enabled: true + + ConsecutiveSilentScripts: + enabled: true + max_consecutive: 2 + + EmptyObjectReference: + enabled: true + + EmptyScript: + enabled: true + + FinalNewline: + enabled: true + present: true + + HtmlAttributes: + enabled: true + + IdNames: + enabled: true + style: snake_case + + ImplicitDiv: + enabled: true + + InstanceVariables: + enabled: true + file_types: partials + matchers: + all: .* + partials: \A_.*\.haml\z + + LeadingCommentSpace: + enabled: true + + LineLength: + enabled: true + max: 200 + + MultilinePipe: + enabled: true + + MultilineScript: + enabled: true + + ObjectReferenceAttributes: + enabled: true + + RepeatedId: + enabled: true + severity: error + + RuboCop: + enabled: true + # These cops are incredibly noisy when it comes to HAML templates, so we + # ignore them. + ignored_cops: + - Lint/BlockAlignment + - Lint/EndAlignment + - Lint/Void + - Metrics/BlockLength + - Metrics/LineLength + - Style/AlignParameters + - Style/BlockNesting + - Style/ElseAlignment + - Style/EndOfLine + - Style/FileName + - Style/FinalNewline + - Style/FrozenStringLiteralComment + - Style/IfUnlessModifier + - Style/IndentationWidth + - Style/Next + - Style/TrailingBlankLines + - Style/TrailingWhitespace + - Style/WhileUntilModifier + + RubyComments: + enabled: true + + SpaceBeforeScript: + enabled: true + + SpaceInsideHashAttributes: + enabled: true + style: space + + Indentation: + enabled: true + character: space # or tab + + TagName: + enabled: true + + TrailingWhitespace: + enabled: true + + UnnecessaryInterpolation: + enabled: true + + UnnecessaryStringOutput: + enabled: true \ No newline at end of file From c3b851d04a89dc16de7f085c672626075fe1a5d0 Mon Sep 17 00:00:00 2001 From: Agrim Mittal Date: Fri, 24 Mar 2017 03:34:33 +0530 Subject: [PATCH 3/9] update Gemfile.lock --- Gemfile.lock | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/Gemfile.lock b/Gemfile.lock index 13b5d012..83c18e4f 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -209,6 +209,11 @@ GEM activesupport (>= 4.0.1) haml (>= 3.1, < 5.0) railties (>= 4.0.1) + haml_lint (0.19.0) + haml (~> 4.0) + rake (>= 10, < 13) + rubocop (>= 0.36.0) + sysexits (~> 1.1) hashie (2.1.1) hike (1.2.3) hoptoad_notifier (2.4.11) @@ -489,6 +494,7 @@ GEM dante (>= 0.2.0) multi_json (>= 1.0.0) stripe (>= 1.31.0, <= 1.43) + sysexits (1.2.0) term-ansicolor (1.3.2) tins (~> 1.0) thor (0.19.1) @@ -574,6 +580,7 @@ DEPENDENCIES gravtastic guard-rspec (~> 4.2.8) haml-rails + haml_lint hoptoad_notifier (~> 2.3) iso-639 jquery-datatables-rails (~> 2.2.1) From 7ae501e08879934323a2c738851edbdf34df4abf Mon Sep 17 00:00:00 2001 From: Agrim Mittal Date: Fri, 24 Mar 2017 03:39:31 +0530 Subject: [PATCH 4/9] change InstanceVariables to false --- .haml-lint.yml | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/.haml-lint.yml b/.haml-lint.yml index 86047884..e1170bd1 100644 --- a/.haml-lint.yml +++ b/.haml-lint.yml @@ -39,11 +39,7 @@ linters: enabled: true InstanceVariables: - enabled: true - file_types: partials - matchers: - all: .* - partials: \A_.*\.haml\z + enabled: false LeadingCommentSpace: enabled: true From 3f159cbf74e2199144005f141c93824a0a2fe242 Mon Sep 17 00:00:00 2001 From: Agrim Mittal Date: Fri, 24 Mar 2017 17:55:30 +0530 Subject: [PATCH 5/9] add empty line at end --- .haml-lint.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.haml-lint.yml b/.haml-lint.yml index e1170bd1..67274347 100644 --- a/.haml-lint.yml +++ b/.haml-lint.yml @@ -109,4 +109,4 @@ linters: enabled: true UnnecessaryStringOutput: - enabled: true \ No newline at end of file + enabled: true From 84ee5cd86b138c53601d53ff890735be7e803a5c Mon Sep 17 00:00:00 2001 From: Agrim Mittal Date: Wed, 29 Mar 2017 14:00:53 +0530 Subject: [PATCH 6/9] add haml-lint_todo.yml --- .haml-lint.yml | 6 +- .haml-lint_todo.yml | 239 ++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 243 insertions(+), 2 deletions(-) create mode 100644 .haml-lint_todo.yml diff --git a/.haml-lint.yml b/.haml-lint.yml index 67274347..efe05f00 100644 --- a/.haml-lint.yml +++ b/.haml-lint.yml @@ -1,3 +1,5 @@ +inherits_from: .haml-lint_todo.yml + linters: AlignmentTabs: enabled: true @@ -33,7 +35,7 @@ linters: IdNames: enabled: true - style: snake_case + style: lisp_case ImplicitDiv: enabled: true @@ -46,7 +48,7 @@ linters: LineLength: enabled: true - max: 200 + max: 500 MultilinePipe: enabled: true diff --git a/.haml-lint_todo.yml b/.haml-lint_todo.yml new file mode 100644 index 00000000..f4d4f7db --- /dev/null +++ b/.haml-lint_todo.yml @@ -0,0 +1,239 @@ +# This configuration was generated by +# `haml-lint --auto-gen-config` +# on 2017-03-29 13:51:32 +0530 using Haml-Lint version 0.24.0. +# The point is for the user to remove these configuration records +# one by one as the lints are removed from the code base. +# Note that changes in the inspected code, or installation of new +# versions of Haml-Lint, may require this file to be generated again. + +linters: + + # Offense count: 43 + IdNames: + exclude: + - "app/views/admin/comments/index.html.haml" + - "app/views/admin/commercials/index.html.haml" + - "app/views/admin/conferences/index.html.haml" + - "app/views/admin/conferences/show.html.haml" + - "app/views/admin/events/_proposal.html.haml" + - "app/views/admin/events/reports.html.haml" + - "app/views/admin/events/show.html.haml" + - "app/views/admin/registrations/index.html.haml" + - "app/views/admin/reports/index.html.haml" + - "app/views/admin/users/show.html.haml" + - "app/views/admin/venues/_form.html.haml" + - "app/views/conference_registrations/_form.html.haml" + - "app/views/conferences/_venue.html.haml" + - "app/views/conferences/show.html.haml" + - "app/views/devise/shared/_help.html.haml" + - "app/views/devise/shared/_sign_in_form_embedded.html.haml" + - "app/views/layouts/_navigation.html.haml" + - "app/views/proposals/_form.html.haml" + - "app/views/proposals/_proposal_form.html.haml" + - "app/views/proposals/index.html.haml" + - "app/views/proposals/new.html.haml" + - "app/views/proposals/show.html.haml" + - "app/views/schedules/_schedule.html.haml" + - "app/views/schedules/show.html.haml" + + # Offense count: 8 + UnnecessaryInterpolation: + exclude: + - "app/views/admin/conferences/_doughnut_chart.html.haml" + - "app/views/admin/conferences/_recent_submissions.html.haml" + - "app/views/admin/events/reports.html.haml" + - "app/views/admin/reports/_events_with_requirements.html.haml" + - "app/views/admin/reports/_events_without_commercials.html.haml" + - "app/views/proposals/_proposal_form.html.haml" + - "app/views/proposals/new.html.haml" + + # Offense count: 48 + UnnecessaryStringOutput: + exclude: + - "app/views/admin/conferences/_targets.html.haml" + - "app/views/admin/event_types/index.html.haml" + - "app/views/admin/events/show.html.haml" + - "app/views/admin/users/_submissions.html.haml" + - "app/views/admin/venues/show.html.haml" + - "app/views/admin/versions/_object_desc_and_link.html.haml" + - "app/views/admin/volunteers/show.html.haml" + - "app/views/conference_registrations/show.html.haml" + - "app/views/conferences/_call_for_paper.html.haml" + - "app/views/conferences/_conference_details.html.haml" + - "app/views/conferences/_program.html.haml" + - "app/views/conferences/_venue.html.haml" + - "app/views/conferences/show.html.haml" + - "app/views/devise/registrations/edit.html.haml" + - "app/views/proposals/_encouragement_text.html.haml" + - "app/views/proposals/_form.html.haml" + - "app/views/users/edit.html.haml" + - "app/views/users/show.html.haml" + + # Offense count: 31 + LineLength: + exclude: + - "app/views/admin/conferences/edit.html.haml" + - "app/views/admin/conferences/new.html.haml" + - "app/views/admin/difficulty_levels/_form.html.haml" + - "app/views/admin/emails/index.html.haml" + - "app/views/admin/events/registrations.html.haml" + - "app/views/admin/programs/_form.html.haml" + - "app/views/admin/roles/_users.html.haml" + - "app/views/admin/sponsorship_levels/_form.html.haml" + - "app/views/admin/venues/_form.html.haml" + - "app/views/conference_registrations/_registration_info.html.haml" + - "app/views/conferences/_venue_map.html.haml" + - "app/views/devise/registrations/_volunteeruser.html.haml" + - "app/views/proposals/index.html.haml" + - "app/views/proposals/show.html.haml" + - "app/views/schedules/_carousel.html.haml" + - "app/views/shared/_object_changes.html.haml" + + # Offense count: 27 + ClassesBeforeIds: + exclude: + - "app/views/admin/emails/index.html.haml" + - "app/views/admin/events/reports.html.haml" + - "app/views/admin/events/show.html.haml" + - "app/views/admin/reports/index.html.haml" + - "app/views/admin/users/show.html.haml" + - "app/views/admin/venues/_form.html.haml" + - "app/views/conferences/index.html.haml" + - "app/views/devise/shared/_help.html.haml" + - "app/views/devise/shared/_sign_in_form_embedded.html.haml" + - "app/views/layouts/_navigation.html.haml" + - "app/views/proposals/_form.html.haml" + + # Offense count: 14 + ConsecutiveSilentScripts: + exclude: + - "app/views/admin/events/index.html.haml" + - "app/views/admin/schedules/_day_tab.html.haml" + - "app/views/admin/schedules/_event.html.haml" + - "app/views/admin/versions/_object_desc_and_link.html.haml" + - "app/views/schedules/_carousel.html.haml" + + # Offense count: 264 + SpaceInsideHashAttributes: + exclude: + - "app/views/admin/questions/_form.html.haml" + - "app/views/admin/questions/index.html.haml" + - "app/views/admin/registrations/index.html.haml" + - "app/views/admin/reports/_all_events.html.haml" + - "app/views/admin/reports/index.html.haml" + - "app/views/admin/schedules/_day_tab.html.haml" + - "app/views/admin/schedules/_event.html.haml" + - "app/views/admin/schedules/index.html.haml" + - "app/views/admin/schedules/show.html.haml" + - "app/views/admin/sponsorship_levels/index.html.haml" + - "app/views/admin/targets/index.html.haml" + - "app/views/admin/tickets/show.html.haml" + - "app/views/admin/tracks/index.html.haml" + - "app/views/admin/users/show.html.haml" + - "app/views/admin/venues/_form.html.haml" + - "app/views/admin/venues/show.html.haml" + - "app/views/conference_registrations/_form.html.haml" + - "app/views/conference_registrations/_ticket.html.haml" + - "app/views/conference_registrations/_volunteer.html.haml" + - "app/views/conferences/_venue.html.haml" + - "app/views/conferences/_venue_map.html.haml" + - "app/views/conferences/index.html.haml" + - "app/views/devise/shared/_help.html.haml" + - "app/views/devise/shared/_openid_links.html.haml" + - "app/views/devise/shared/_sign_in_form_embedded.html.haml" + - "app/views/layouts/_admin_sidebar.html.haml" + - "app/views/layouts/_admin_sidebar_index.html.haml" + - "app/views/layouts/_messages.html.haml" + - "app/views/layouts/_navigation.html.haml" + - "app/views/layouts/application.html.haml" + - "app/views/payments/_payment.html.haml" + - "app/views/proposals/_form.html.haml" + - "app/views/proposals/_tooltip.html.haml" + - "app/views/proposals/index.html.haml" + - "app/views/proposals/new.html.haml" + - "app/views/proposals/show.html.haml" + - "app/views/schedules/_carousel.html.haml" + - "app/views/schedules/_schedule_item.html.haml" + - "app/views/shared/_changelog_actions.haml" + - "app/views/shared/_dynamic_association.html.haml" + - "app/views/shared/_media_item.html.haml" + - "app/views/shared/_media_items.html.haml" + - "app/views/shared/_object_changes.html.haml" + - "app/views/tickets/_ticket.html.haml" + - "app/views/tickets/index.html.haml" + + # Offense count: 2 + FinalNewline: + exclude: + - "app/views/admin/registrations/index.csv.haml" + - "app/views/layouts/_admin.html.haml" + + # Offense count: 1 + ImplicitDiv: + exclude: + - "app/views/admin/registrations/index.html.haml" + + # Offense count: 48 + SpaceBeforeScript: + exclude: + - "app/views/admin/registrations/index.html.haml" + - "app/views/admin/sponsors/_form.html.haml" + - "app/views/admin/targets/_form.html.haml" + - "app/views/admin/tracks/_form.html.haml" + - "app/views/admin/tracks/show.html.haml" + - "app/views/admin/venues/show.html.haml" + - "app/views/admin/versions/index.html.haml" + - "app/views/conference_registrations/_form.html.haml" + - "app/views/conference_registrations/_ticket.html.haml" + - "app/views/conference_registrations/show.html.haml" + - "app/views/conferences/_lodging.html.haml" + - "app/views/conferences/_schedule_splashpage.html.haml" + - "app/views/conferences/_sponsors.html.haml" + - "app/views/conferences/_tickets.html.haml" + - "app/views/conferences/_venue.html.haml" + - "app/views/conferences/index.html.haml" + - "app/views/layouts/_admin.html.haml" + - "app/views/layouts/_navigation.html.haml" + - "app/views/layouts/_user_menu.html.haml" + - "app/views/layouts/application.html.haml" + - "app/views/proposals/_encouragement_text.html.haml" + - "app/views/proposals/new.html.haml" + - "app/views/proposals/registrations.html.haml" + - "app/views/proposals/show.html.haml" + - "app/views/schedules/events.html.haml" + - "app/views/schedules/show.xml.haml" + - "app/views/tickets/index.html.haml" + + # Offense count: 9 + MultilinePipe: + exclude: + - "app/views/admin/schedules/_day_tab.html.haml" + - "app/views/admin/schedules/_event.html.haml" + - "app/views/schedules/_carousel.html.haml" + - "app/views/schedules/_event.html.haml" + - "app/views/schedules/_schedule_item.html.haml" + + # Offense count: 38 + TrailingWhitespace: + exclude: + - "app/views/admin/users/_form.html.haml" + - "app/views/admin/users/index.html.haml" + - "app/views/admin/users/show.html.haml" + - "app/views/admin/volunteers/index.html.haml" + - "app/views/admin/volunteers/show.html.haml" + - "app/views/conference_registrations/_volunteer.html.haml" + - "app/views/devise/passwords/new.html.haml" + - "app/views/payments/new.html.haml" + - "app/views/tickets/index.html.haml" + + # Offense count: 1 + AltText: + exclude: + - "app/views/admin/venues/show.html.haml" + + # Offense count: 7 + ClassAttributeWithStaticValue: + exclude: + - "app/views/conferences/_gallery.html.haml" + - "app/views/layouts/_navigation.html.haml" + - "app/views/schedules/events.html.haml" \ No newline at end of file From 1d5c3d6345ae5a2ebf46199036478f8b4142a0a5 Mon Sep 17 00:00:00 2001 From: Agrim Mittal Date: Thu, 30 Mar 2017 20:00:08 +0530 Subject: [PATCH 7/9] Update haml_lint to 0.24.0 --- Gemfile | 2 +- Gemfile.lock | 35 +++++++++++++++++------------------ 2 files changed, 18 insertions(+), 19 deletions(-) diff --git a/Gemfile b/Gemfile index ccfd3870..cd1739d3 100644 --- a/Gemfile +++ b/Gemfile @@ -198,7 +198,7 @@ group :development do # to launch specs when files are modified gem 'guard-rspec', '~> 4.2.8' gem 'spring-commands-rspec' - gem 'haml_lint' + gem 'haml_lint', '~> 0.24.0' # for static code analisys gem 'rubocop', require: false # as database diff --git a/Gemfile.lock b/Gemfile.lock index 83c18e4f..c4449ac9 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -58,7 +58,7 @@ GEM user_agent_parser uuidtools arel (6.0.3) - ast (2.2.0) + ast (2.3.0) autoprefixer-rails (5.1.9) execjs json @@ -202,17 +202,18 @@ GEM guard-rspec (4.2.8) guard (~> 2.1) rspec (>= 2.14, < 4.0) - haml (4.0.5) + haml (4.0.7) tilt haml-rails (0.5.3) actionpack (>= 4.0.1) activesupport (>= 4.0.1) haml (>= 3.1, < 5.0) railties (>= 4.0.1) - haml_lint (0.19.0) - haml (~> 4.0) + haml_lint (0.24.0) + haml (>= 4.0, < 5.1) + rainbow rake (>= 10, < 13) - rubocop (>= 0.36.0) + rubocop (>= 0.47.0) sysexits (~> 1.1) hashie (2.1.1) hike (1.2.3) @@ -285,9 +286,8 @@ GEM mysql2 (0.4.2) netrc (0.11.0) nio4r (1.2.1) - nokogiri (1.7.1) + nokogiri (1.6.8.1) mini_portile2 (~> 2.1.0) - pkg-config (~> 1.1.7) oauth2 (0.9.4) faraday (>= 0.8, < 0.10) jwt (~> 1.0) @@ -319,7 +319,7 @@ GEM activerecord (>= 3.0, < 6.0) activesupport (>= 3.0, < 6.0) request_store (~> 1.1) - parser (2.3.0.3) + parser (2.4.0.0) ast (~> 2.2) pdf-core (0.2.5) phantomjs (2.1.1.0) @@ -327,7 +327,6 @@ GEM actionpack activesupport rails (>= 3.0.0) - pkg-config (1.1.7) poltergeist (1.9.0) capybara (~> 2.1) cliver (~> 0.3.1) @@ -401,8 +400,8 @@ GEM activesupport (= 4.2.7.1) rake (>= 0.8.7) thor (>= 0.18.1, < 2.0) - rainbow (2.1.0) - rake (10.5.0) + rainbow (2.2.1) + rake (12.0.0) rb-fsevent (0.9.4) rb-inotify (0.9.4) ffi (>= 0.5.0) @@ -447,15 +446,15 @@ GEM rspec-mocks (~> 3.0.0) rspec-support (~> 3.0.0) rspec-support (3.0.2) - rubocop (0.37.0) - parser (>= 2.3.0.2, < 3.0) + rubocop (0.48.0) + parser (>= 2.3.3.1, < 3.0) powerpack (~> 0.1) rainbow (>= 1.99.1, < 3.0) ruby-progressbar (~> 1.7) - unicode-display_width (~> 0.3) + unicode-display_width (~> 1.0, >= 1.0.1) ruby-oembed (0.8.14) ruby-openid (2.5.0) - ruby-progressbar (1.7.5) + ruby-progressbar (1.8.1) rubyzip (1.2.1) safe_yaml (1.0.4) sass (3.2.19) @@ -514,7 +513,7 @@ GEM unf (0.1.4) unf_ext unf_ext (0.0.7.2) - unicode-display_width (0.3.1) + unicode-display_width (1.1.3) unicode_utils (1.4.0) unobtrusive_flash (3.1.0) railties @@ -580,7 +579,7 @@ DEPENDENCIES gravtastic guard-rspec (~> 4.2.8) haml-rails - haml_lint + haml_lint (~> 0.24.0) hoptoad_notifier (~> 2.3) iso-639 jquery-datatables-rails (~> 2.2.1) @@ -644,4 +643,4 @@ DEPENDENCIES whenever BUNDLED WITH - 1.14.3 + 1.14.5 From 246274301e34a153763c61998277e18cf89c3850 Mon Sep 17 00:00:00 2001 From: Agrim Mittal Date: Fri, 31 Mar 2017 00:03:49 +0530 Subject: [PATCH 8/9] update haml-lint.yml --- .haml-lint.yml | 113 ----------------- .haml-lint_todo.yml | 294 +++++++++++++++++++++++++++++++++++--------- 2 files changed, 238 insertions(+), 169 deletions(-) diff --git a/.haml-lint.yml b/.haml-lint.yml index efe05f00..013b144f 100644 --- a/.haml-lint.yml +++ b/.haml-lint.yml @@ -1,114 +1 @@ inherits_from: .haml-lint_todo.yml - -linters: - AlignmentTabs: - enabled: true - - AltText: - enabled: true - - ClassAttributeWithStaticValue: - enabled: true - - ClassesBeforeIds: - enabled: true - - ConsecutiveComments: - enabled: true - - ConsecutiveSilentScripts: - enabled: true - max_consecutive: 2 - - EmptyObjectReference: - enabled: true - - EmptyScript: - enabled: true - - FinalNewline: - enabled: true - present: true - - HtmlAttributes: - enabled: true - - IdNames: - enabled: true - style: lisp_case - - ImplicitDiv: - enabled: true - - InstanceVariables: - enabled: false - - LeadingCommentSpace: - enabled: true - - LineLength: - enabled: true - max: 500 - - MultilinePipe: - enabled: true - - MultilineScript: - enabled: true - - ObjectReferenceAttributes: - enabled: true - - RepeatedId: - enabled: true - severity: error - - RuboCop: - enabled: true - # These cops are incredibly noisy when it comes to HAML templates, so we - # ignore them. - ignored_cops: - - Lint/BlockAlignment - - Lint/EndAlignment - - Lint/Void - - Metrics/BlockLength - - Metrics/LineLength - - Style/AlignParameters - - Style/BlockNesting - - Style/ElseAlignment - - Style/EndOfLine - - Style/FileName - - Style/FinalNewline - - Style/FrozenStringLiteralComment - - Style/IfUnlessModifier - - Style/IndentationWidth - - Style/Next - - Style/TrailingBlankLines - - Style/TrailingWhitespace - - Style/WhileUntilModifier - - RubyComments: - enabled: true - - SpaceBeforeScript: - enabled: true - - SpaceInsideHashAttributes: - enabled: true - style: space - - Indentation: - enabled: true - character: space # or tab - - TagName: - enabled: true - - TrailingWhitespace: - enabled: true - - UnnecessaryInterpolation: - enabled: true - - UnnecessaryStringOutput: - enabled: true diff --git a/.haml-lint_todo.yml b/.haml-lint_todo.yml index f4d4f7db..19e8a46d 100644 --- a/.haml-lint_todo.yml +++ b/.haml-lint_todo.yml @@ -1,6 +1,6 @@ # This configuration was generated by # `haml-lint --auto-gen-config` -# on 2017-03-29 13:51:32 +0530 using Haml-Lint version 0.24.0. +# on 2017-03-31 00:02:02 +0530 using Haml-Lint version 0.24.0. # The point is for the user to remove these configuration records # one by one as the lints are removed from the code base. # Note that changes in the inspected code, or installation of new @@ -8,33 +8,239 @@ linters: - # Offense count: 43 - IdNames: + # Offense count: 943 + LineLength: exclude: - - "app/views/admin/comments/index.html.haml" + - "app/views/admin/campaigns/_form.html.haml" + - "app/views/admin/campaigns/index.html.haml" + - "app/views/admin/cfps/_form.html.haml" + - "app/views/admin/cfps/show.html.haml" + - "app/views/admin/comments/_all_comments.html.haml" + - "app/views/admin/comments/_posted_comments.html.haml" + - "app/views/admin/comments/_unread_comments.html.haml" - "app/views/admin/commercials/index.html.haml" + - "app/views/admin/conferences/_campaigns.html.haml" + - "app/views/admin/conferences/_doughnut_chart.html.haml" + - "app/views/admin/conferences/_line_chart.html.haml" + - "app/views/admin/conferences/_recent_registrations.html.haml" + - "app/views/admin/conferences/_recent_submissions.html.haml" + - "app/views/admin/conferences/_recent_users.html.haml" + - "app/views/admin/conferences/_targets.html.haml" + - "app/views/admin/conferences/_todo_list.html.haml" + - "app/views/admin/conferences/_top_submitter.html.haml" + - "app/views/admin/conferences/edit.html.haml" - "app/views/admin/conferences/index.html.haml" + - "app/views/admin/conferences/new.html.haml" - "app/views/admin/conferences/show.html.haml" + - "app/views/admin/contacts/edit.html.haml" + - "app/views/admin/difficulty_levels/_form.html.haml" + - "app/views/admin/difficulty_levels/index.html.haml" + - "app/views/admin/emails/_help.html.haml" + - "app/views/admin/emails/index.html.haml" + - "app/views/admin/event_types/_form.html.haml" + - "app/views/admin/event_types/index.html.haml" + - "app/views/admin/events/_all_events.csv.haml" + - "app/views/admin/events/_all_with_comments.csv.haml" + - "app/views/admin/events/_change_state_dropdown.html.haml" + - "app/views/admin/events/_confirmed_events.csv.haml" + - "app/views/admin/events/_nested_comments.html.haml" - "app/views/admin/events/_proposal.html.haml" + - "app/views/admin/events/_voting.html.haml" + - "app/views/admin/events/_voting_index.html.haml" + - "app/views/admin/events/index.html.haml" + - "app/views/admin/events/registrations.html.haml" - "app/views/admin/events/reports.html.haml" - "app/views/admin/events/show.html.haml" + - "app/views/admin/lodgings/_form.html.haml" + - "app/views/admin/lodgings/index.html.haml" + - "app/views/admin/programs/_form.html.haml" + - "app/views/admin/programs/show.html.haml" + - "app/views/admin/questions/_form.html.haml" + - "app/views/admin/questions/_questions.html.haml" + - "app/views/admin/questions/edit.html.haml" + - "app/views/admin/questions/index.html.haml" + - "app/views/admin/questions/show.html.haml" + - "app/views/admin/registration_periods/_form.html.haml" + - "app/views/admin/registration_periods/show.html.haml" + - "app/views/admin/registrations/edit.html.haml" - "app/views/admin/registrations/index.html.haml" - - "app/views/admin/reports/index.html.haml" + - "app/views/admin/reports/_all_events.html.haml" + - "app/views/admin/reports/_events_with_requirements.html.haml" + - "app/views/admin/reports/_events_without_commercials.html.haml" + - "app/views/admin/reports/_missing_speakers.html.haml" + - "app/views/admin/resources/_form.html.haml" + - "app/views/admin/resources/index.html.haml" + - "app/views/admin/resources/show.html.haml" + - "app/views/admin/roles/_form.html.haml" + - "app/views/admin/roles/_users.html.haml" + - "app/views/admin/roles/index.html.haml" + - "app/views/admin/roles/show.html.haml" + - "app/views/admin/rooms/_form.html.haml" + - "app/views/admin/rooms/index.html.haml" + - "app/views/admin/schedules/_day_tab.html.haml" + - "app/views/admin/schedules/_event.html.haml" + - "app/views/admin/schedules/index.html.haml" + - "app/views/admin/schedules/show.html.haml" + - "app/views/admin/splashpages/_form.html.haml" + - "app/views/admin/splashpages/show.html.haml" + - "app/views/admin/sponsors/_form.html.haml" + - "app/views/admin/sponsors/index.html.haml" + - "app/views/admin/sponsorship_levels/_form.html.haml" + - "app/views/admin/sponsorship_levels/index.html.haml" + - "app/views/admin/targets/_form.html.haml" + - "app/views/admin/targets/index.html.haml" + - "app/views/admin/tickets/_form.html.haml" + - "app/views/admin/tickets/index.html.haml" + - "app/views/admin/tickets/show.html.haml" + - "app/views/admin/tracks/_form.html.haml" + - "app/views/admin/tracks/index.html.haml" + - "app/views/admin/tracks/show.html.haml" + - "app/views/admin/users/_event_registrations.html.haml" + - "app/views/admin/users/_form.html.haml" + - "app/views/admin/users/_submissions.html.haml" + - "app/views/admin/users/index.html.haml" - "app/views/admin/users/show.html.haml" - "app/views/admin/venues/_form.html.haml" + - "app/views/admin/venues/show.html.haml" + - "app/views/admin/versions/_object_desc_and_link.html.haml" + - "app/views/admin/versions/index.html.haml" + - "app/views/admin/volunteers/index.html.haml" + - "app/views/commercials/edit.html.haml" + - "app/views/commercials/new.html.haml" - "app/views/conference_registrations/_form.html.haml" + - "app/views/conference_registrations/_questions.html.haml" + - "app/views/conference_registrations/_registration_info.html.haml" + - "app/views/conference_registrations/_volunteer.html.haml" + - "app/views/conference_registrations/show.html.haml" + - "app/views/conferences/_call_for_paper.html.haml" + - "app/views/conferences/_conference_details.html.haml" + - "app/views/conferences/_gallery.html.haml" + - "app/views/conferences/_lodging.html.haml" + - "app/views/conferences/_program.html.haml" + - "app/views/conferences/_registration.html.haml" + - "app/views/conferences/_schedule_splashpage.html.haml" + - "app/views/conferences/_sponsors.html.haml" + - "app/views/conferences/_tickets.html.haml" - "app/views/conferences/_venue.html.haml" + - "app/views/conferences/_venue_map.html.haml" + - "app/views/conferences/index.html.haml" - "app/views/conferences/show.html.haml" + - "app/views/devise/confirmations/new.html.haml" + - "app/views/devise/ichain_sessions/new.html.haml" + - "app/views/devise/ichain_sessions/new_test.html.haml" + - "app/views/devise/passwords/edit.html.haml" + - "app/views/devise/passwords/new.html.haml" + - "app/views/devise/registrations/_volunteeruser.html.haml" + - "app/views/devise/registrations/edit.html.haml" + - "app/views/devise/registrations/new.html.haml" + - "app/views/devise/sessions/new.html.haml" - "app/views/devise/shared/_help.html.haml" + - "app/views/devise/shared/_links.html.haml" + - "app/views/devise/shared/_openid_links.html.haml" - "app/views/devise/shared/_sign_in_form_embedded.html.haml" + - "app/views/devise/shared/_sign_up_form_embedded.html.haml" + - "app/views/layouts/_admin_sidebar.html.haml" + - "app/views/layouts/_admin_sidebar_index.html.haml" + - "app/views/layouts/_messages.html.haml" - "app/views/layouts/_navigation.html.haml" + - "app/views/layouts/application.html.haml" + - "app/views/payments/_payment.html.haml" - "app/views/proposals/_form.html.haml" - "app/views/proposals/_proposal_form.html.haml" + - "app/views/proposals/_tooltip.html.haml" - "app/views/proposals/index.html.haml" - "app/views/proposals/new.html.haml" + - "app/views/proposals/registrations.html.haml" - "app/views/proposals/show.html.haml" + - "app/views/schedules/_carousel.html.haml" + - "app/views/schedules/_event.html.haml" - "app/views/schedules/_schedule.html.haml" + - "app/views/schedules/_schedule_item.html.haml" + - "app/views/schedules/_schedule_tabs.html.haml" + - "app/views/schedules/events.html.haml" - "app/views/schedules/show.html.haml" + - "app/views/schedules/show.xml.haml" + - "app/views/shared/_changelog_actions.haml" + - "app/views/shared/_dynamic_association.html.haml" + - "app/views/shared/_media_item.html.haml" + - "app/views/shared/_media_items.html.haml" + - "app/views/shared/_object_changes.html.haml" + - "app/views/tickets/_ticket.html.haml" + - "app/views/tickets/index.html.haml" + - "app/views/users/edit.html.haml" + - "app/views/users/show.html.haml" + + # Offense count: 204 + InstanceVariables: + exclude: + - "app/views/admin/campaigns/_form.html.haml" + - "app/views/admin/cfps/_form.html.haml" + - "app/views/admin/conferences/_todo_list.html.haml" + - "app/views/admin/difficulty_levels/_form.html.haml" + - "app/views/admin/event_types/_form.html.haml" + - "app/views/admin/events/_change_state_dropdown.html.haml" + - "app/views/admin/events/_proposal.html.haml" + - "app/views/admin/events/_voting.html.haml" + - "app/views/admin/events/_voting_index.html.haml" + - "app/views/admin/lodgings/_form.html.haml" + - "app/views/admin/questions/_questions.html.haml" + - "app/views/admin/registration_periods/_form.html.haml" + - "app/views/admin/reports/_all_events.html.haml" + - "app/views/admin/reports/_events_with_requirements.html.haml" + - "app/views/admin/reports/_events_without_commercials.html.haml" + - "app/views/admin/reports/_missing_speakers.html.haml" + - "app/views/admin/roles/_form.html.haml" + - "app/views/admin/roles/_users.html.haml" + - "app/views/admin/rooms/_form.html.haml" + - "app/views/admin/schedules/_day_tab.html.haml" + - "app/views/admin/sponsors/_form.html.haml" + - "app/views/admin/sponsorship_levels/_form.html.haml" + - "app/views/admin/tickets/_form.html.haml" + - "app/views/admin/tracks/_form.html.haml" + - "app/views/admin/users/_form.html.haml" + - "app/views/admin/users/_submissions.html.haml" + - "app/views/admin/venues/_form.html.haml" + - "app/views/conference_registrations/_form.html.haml" + - "app/views/conference_registrations/_registration_info.html.haml" + - "app/views/conference_registrations/_volunteer.html.haml" + - "app/views/conferences/_call_for_paper.html.haml" + - "app/views/conferences/_lodging.html.haml" + - "app/views/conferences/_program.html.haml" + - "app/views/conferences/_registration.html.haml" + - "app/views/conferences/_schedule_splashpage.html.haml" + - "app/views/conferences/_sponsors.html.haml" + - "app/views/conferences/_tickets.html.haml" + - "app/views/conferences/_venue.html.haml" + - "app/views/conferences/_venue_map.html.haml" + - "app/views/layouts/_admin_sidebar.html.haml" + - "app/views/layouts/_user_menu.html.haml" + - "app/views/payments/_payment.html.haml" + - "app/views/proposals/_encouragement_text.html.haml" + - "app/views/proposals/_form.html.haml" + - "app/views/proposals/_proposal_form.html.haml" + - "app/views/schedules/_carousel.html.haml" + - "app/views/schedules/_event.html.haml" + - "app/views/schedules/_schedule.html.haml" + - "app/views/schedules/_schedule_item.html.haml" + - "app/views/schedules/_schedule_tabs.html.haml" + + # Offense count: 32 + IdNames: + exclude: + - "app/views/admin/cfps/show.html.haml" + - "app/views/admin/comments/index.html.haml" + - "app/views/admin/conferences/index.html.haml" + - "app/views/admin/conferences/show.html.haml" + - "app/views/admin/difficulty_levels/index.html.haml" + - "app/views/admin/event_types/index.html.haml" + - "app/views/admin/programs/show.html.haml" + - "app/views/admin/questions/show.html.haml" + - "app/views/admin/roles/show.html.haml" + - "app/views/admin/schedules/index.html.haml" + - "app/views/admin/sponsorship_levels/index.html.haml" + - "app/views/admin/users/_event_registrations.html.haml" + - "app/views/admin/users/show.html.haml" + - "app/views/users/edit.html.haml" # Offense count: 8 UnnecessaryInterpolation: @@ -69,53 +275,10 @@ linters: - "app/views/users/edit.html.haml" - "app/views/users/show.html.haml" - # Offense count: 31 - LineLength: - exclude: - - "app/views/admin/conferences/edit.html.haml" - - "app/views/admin/conferences/new.html.haml" - - "app/views/admin/difficulty_levels/_form.html.haml" - - "app/views/admin/emails/index.html.haml" - - "app/views/admin/events/registrations.html.haml" - - "app/views/admin/programs/_form.html.haml" - - "app/views/admin/roles/_users.html.haml" - - "app/views/admin/sponsorship_levels/_form.html.haml" - - "app/views/admin/venues/_form.html.haml" - - "app/views/conference_registrations/_registration_info.html.haml" - - "app/views/conferences/_venue_map.html.haml" - - "app/views/devise/registrations/_volunteeruser.html.haml" - - "app/views/proposals/index.html.haml" - - "app/views/proposals/show.html.haml" - - "app/views/schedules/_carousel.html.haml" - - "app/views/shared/_object_changes.html.haml" - - # Offense count: 27 - ClassesBeforeIds: - exclude: - - "app/views/admin/emails/index.html.haml" - - "app/views/admin/events/reports.html.haml" - - "app/views/admin/events/show.html.haml" - - "app/views/admin/reports/index.html.haml" - - "app/views/admin/users/show.html.haml" - - "app/views/admin/venues/_form.html.haml" - - "app/views/conferences/index.html.haml" - - "app/views/devise/shared/_help.html.haml" - - "app/views/devise/shared/_sign_in_form_embedded.html.haml" - - "app/views/layouts/_navigation.html.haml" - - "app/views/proposals/_form.html.haml" - - # Offense count: 14 - ConsecutiveSilentScripts: - exclude: - - "app/views/admin/events/index.html.haml" - - "app/views/admin/schedules/_day_tab.html.haml" - - "app/views/admin/schedules/_event.html.haml" - - "app/views/admin/versions/_object_desc_and_link.html.haml" - - "app/views/schedules/_carousel.html.haml" - - # Offense count: 264 + # Offense count: 268 SpaceInsideHashAttributes: exclude: + - "app/views/admin/conferences/_todo_list.html.haml" - "app/views/admin/questions/_form.html.haml" - "app/views/admin/questions/index.html.haml" - "app/views/admin/registrations/index.html.haml" @@ -162,6 +325,30 @@ linters: - "app/views/tickets/_ticket.html.haml" - "app/views/tickets/index.html.haml" + # Offense count: 27 + ClassesBeforeIds: + exclude: + - "app/views/admin/emails/index.html.haml" + - "app/views/admin/events/reports.html.haml" + - "app/views/admin/events/show.html.haml" + - "app/views/admin/reports/index.html.haml" + - "app/views/admin/users/show.html.haml" + - "app/views/admin/venues/_form.html.haml" + - "app/views/conferences/index.html.haml" + - "app/views/devise/shared/_help.html.haml" + - "app/views/devise/shared/_sign_in_form_embedded.html.haml" + - "app/views/layouts/_navigation.html.haml" + - "app/views/proposals/_form.html.haml" + + # Offense count: 14 + ConsecutiveSilentScripts: + exclude: + - "app/views/admin/events/index.html.haml" + - "app/views/admin/schedules/_day_tab.html.haml" + - "app/views/admin/schedules/_event.html.haml" + - "app/views/admin/versions/_object_desc_and_link.html.haml" + - "app/views/schedules/_carousel.html.haml" + # Offense count: 2 FinalNewline: exclude: @@ -226,14 +413,9 @@ linters: - "app/views/payments/new.html.haml" - "app/views/tickets/index.html.haml" - # Offense count: 1 - AltText: - exclude: - - "app/views/admin/venues/show.html.haml" - # Offense count: 7 ClassAttributeWithStaticValue: exclude: - "app/views/conferences/_gallery.html.haml" - "app/views/layouts/_navigation.html.haml" - - "app/views/schedules/events.html.haml" \ No newline at end of file + - "app/views/schedules/events.html.haml" From efa700f23c8019333199a8a4a5a48c2fa843500b Mon Sep 17 00:00:00 2001 From: Agrim Mittal Date: Fri, 31 Mar 2017 14:29:09 +0530 Subject: [PATCH 9/9] Fix compatibility issues --- Gemfile.lock | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/Gemfile.lock b/Gemfile.lock index c4449ac9..a678aa68 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -82,7 +82,7 @@ GEM bootstrap3-datetimepicker-rails (3.0.3) momentjs-rails (>= 2.8.1) browser (0.6.0) - builder (3.2.2) + builder (3.2.3) byebug (3.1.2) columnize (~> 0.8) debugger-linecache (~> 1.2) @@ -160,7 +160,7 @@ GEM warden (~> 1.2.3) devise_ichain_authenticatable (0.3.1) devise (>= 2.2) - diff-lcs (1.2.5) + diff-lcs (1.3) docile (1.1.5) domain_name (0.5.20160310) unf (>= 0.0.5, < 1.0.0) @@ -213,7 +213,7 @@ GEM haml (>= 4.0, < 5.1) rainbow rake (>= 10, < 13) - rubocop (>= 0.47.0) + rubocop (>= 0.36.0) sysexits (~> 1.1) hashie (2.1.1) hike (1.2.3) @@ -236,7 +236,7 @@ GEM thor (>= 0.14, < 2.0) jquery-ui-rails (4.2.1) railties (>= 3.2.16) - json (1.8.3) + json (1.8.6) json-schema (2.5.0) addressable (~> 2.3) jwt (1.0.0) @@ -267,7 +267,7 @@ GEM rake mini_magick (4.5.1) mini_portile2 (2.1.0) - minitest (5.9.0) + minitest (5.10.1) momentjs-rails (2.8.1) railties (>= 3.1) monetize (1.4.0) @@ -286,7 +286,7 @@ GEM mysql2 (0.4.2) netrc (0.11.0) nio4r (1.2.1) - nokogiri (1.6.8.1) + nokogiri (1.7.1) mini_portile2 (~> 2.1.0) oauth2 (0.9.4) faraday (>= 0.8, < 0.10) @@ -401,7 +401,7 @@ GEM rake (>= 0.8.7) thor (>= 0.18.1, < 2.0) rainbow (2.2.1) - rake (12.0.0) + rake (10.5.0) rb-fsevent (0.9.4) rb-inotify (0.9.4) ffi (>= 0.5.0) @@ -430,12 +430,12 @@ GEM activemodel (>= 3.0) activesupport (>= 3.0) rspec-mocks (>= 2.99, < 4.0) - rspec-core (3.0.2) + rspec-core (3.0.4) rspec-support (~> 3.0.0) - rspec-expectations (3.0.2) + rspec-expectations (3.0.4) diff-lcs (>= 1.2.0, < 2.0) rspec-support (~> 3.0.0) - rspec-mocks (3.0.2) + rspec-mocks (3.0.4) rspec-support (~> 3.0.0) rspec-rails (3.0.0) actionpack (>= 3.0) @@ -445,8 +445,8 @@ GEM rspec-expectations (~> 3.0.0) rspec-mocks (~> 3.0.0) rspec-support (~> 3.0.0) - rspec-support (3.0.2) - rubocop (0.48.0) + rspec-support (3.0.4) + rubocop (0.37.0) parser (>= 2.3.3.1, < 3.0) powerpack (~> 0.1) rainbow (>= 1.99.1, < 3.0) @@ -497,7 +497,7 @@ GEM term-ansicolor (1.3.2) tins (~> 1.0) thor (0.19.1) - thread_safe (0.3.5) + thread_safe (0.3.6) tilt (1.4.1) timecop (0.7.1) timers (1.1.0) @@ -506,7 +506,7 @@ GEM ttfunk (1.1.1) turbolinks (2.5.3) coffee-rails - tzinfo (1.2.2) + tzinfo (1.2.3) thread_safe (~> 0.1) uglifier (3.0.0) execjs (>= 0.3.0, < 3)