From 9e34c57d5e698b7ef88c51051f17ea943d6b0bc0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9my=20Coutable?= Date: Mon, 12 Sep 2016 19:36:24 +0200 Subject: Add haml_lint rake task MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Rémy Coutable --- .gitlab-ci.yml | 2 +- lib/tasks/haml-lint.rake | 8 ++++++++ 2 files changed, 9 insertions(+), 1 deletion(-) create mode 100644 lib/tasks/haml-lint.rake diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 1b777f5016f..b5eef681d0e 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -206,7 +206,7 @@ spinach 9 10 ruby21: *spinach-knapsack-ruby21 - bundle exec $CI_BUILD_NAME rubocop: *exec -rake haml-lint: *exec +rake haml_lint: *exec rake scss_lint: *exec rake brakeman: *exec rake flog: *exec diff --git a/lib/tasks/haml-lint.rake b/lib/tasks/haml-lint.rake new file mode 100644 index 00000000000..80f70820853 --- /dev/null +++ b/lib/tasks/haml-lint.rake @@ -0,0 +1,8 @@ +unless Rails.env.production? + require 'haml_lint/rake_task' + + HamlLint::RakeTask.new do |t| + t.config = '.haml-lint.yml' + t.files = ['app/views'] + end +end -- cgit v1.2.1