From 017b8f196049abc897ee57643b728a8793496f6c Mon Sep 17 00:00:00 2001 From: David O'Sullivan Date: Mon, 20 Mar 2023 12:38:47 +0000 Subject: [PATCH] Fixes rubocop violations --- bin/ruby-run | 44 ++++++++++++++++---------------- rakelib/dependency_cache_task.rb | 2 +- 2 files changed, 23 insertions(+), 23 deletions(-) diff --git a/bin/ruby-run b/bin/ruby-run index 598cb27d6a..c8188ae68b 100755 --- a/bin/ruby-run +++ b/bin/ruby-run @@ -22,29 +22,29 @@ $LOAD_PATH.unshift File.expand_path('../lib', __dir__) require 'java_buildpack/buildpack' case ARGV[0] - when "compile" - app_dir = ARGV[1] - JavaBuildpack::Buildpack.with_buildpack(app_dir, nil, nil, 'Compile failed with exception %s', &:compile) +when 'compile' + app_dir = ARGV[1] + JavaBuildpack::Buildpack.with_buildpack(app_dir, nil, nil, 'Compile failed with exception %s', &:compile) - when "detect" - app_dir = ARGV[1] - components = JavaBuildpack::Buildpack.with_buildpack(app_dir, nil, nil, 'Detect failed with exception %s', - &:detect).compact - if components.empty? - abort - else - str = components.join(' ') - puts str.length > 255 ? str.slice(0..251) + '...' : str - end +when 'detect' + app_dir = ARGV[1] + components = JavaBuildpack::Buildpack.with_buildpack(app_dir, nil, nil, 'Detect failed with exception %s', + &:detect).compact + if components.empty? + abort + else + str = components.join(' ') + puts str.length > 255 ? str.slice(0..251) + '...' : str + end - when "finalize" - app_dir = ARGV[1] - deps_dir = ARGV[3] - index = ARGV[4] - JavaBuildpack::Buildpack.with_buildpack(app_dir, deps_dir, index, 'Finalize failed with exception %s', &:compile) +when 'finalize' + app_dir = ARGV[1] + deps_dir = ARGV[3] + index = ARGV[4] + JavaBuildpack::Buildpack.with_buildpack(app_dir, deps_dir, index, 'Finalize failed with exception %s', &:compile) - when "release" - app_dir = ARGV[1] - output = JavaBuildpack::Buildpack.with_buildpack(app_dir, nil, nil, 'Release failed with exception %s', &:release) - puts output +when 'release' + app_dir = ARGV[1] + output = JavaBuildpack::Buildpack.with_buildpack(app_dir, nil, nil, 'Release failed with exception %s', &:release) + puts output end diff --git a/rakelib/dependency_cache_task.rb b/rakelib/dependency_cache_task.rb index 3e07630160..12d3d54845 100644 --- a/rakelib/dependency_cache_task.rb +++ b/rakelib/dependency_cache_task.rb @@ -119,7 +119,7 @@ def component_ids offline_cache = offline_cache.split(',') (conf << offline_cache).flatten!.uniq! end - conf << "ruby" + conf << 'ruby' end def component_configuration(component_id)