From 4e3978b4395a97ccbab7a322f50700e14fe0a972 Mon Sep 17 00:00:00 2001 From: akadusei Date: Sat, 1 Jun 2024 22:04:33 +0000 Subject: [PATCH] Fix CI errors --- .rubocop.yml | 3 +++ lib/envy.rb | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/.rubocop.yml b/.rubocop.yml index 6c54972..f91f2bd 100644 --- a/.rubocop.yml +++ b/.rubocop.yml @@ -9,6 +9,9 @@ AllCops: Lint/AssignmentInCondition: Enabled: false +Lint/ScriptPermission: + Enabled: false + RSpec/ExampleLength: Enabled: false diff --git a/lib/envy.rb b/lib/envy.rb index 579c083..4e0d4c3 100644 --- a/lib/envy.rb +++ b/lib/envy.rb @@ -47,12 +47,12 @@ def set_perms(files, perm: nil) # rubocop:disable Metrics/MethodLength, Metrics/CyclomaticComplexity def set_envs(yaml, prev_key = "", force:) case yaml - when Hash + when ::Hash yaml.each do |key, value| env_key = "#{prev_key}_#{key.to_s.upcase}".sub(/\A_/, "") set_envs(value, env_key, force: force) end - when Array, Set + when ::Array, ::Set yaml.each_with_index do |value, index| env_key = "#{prev_key}_#{index}".sub(/\A_/, "") set_envs(value, env_key, force: force)