Replaced string interpolations with to build paths
This commit is contained in:
@@ -21,7 +21,7 @@ class Kamal::Commands::Auditor < Kamal::Commands::Base
|
||||
def audit_log_file
|
||||
file = [ config.service, config.destination, "audit.log" ].compact.join("-")
|
||||
|
||||
"#{config.run_directory}/#{file}"
|
||||
File.join(config.run_directory, file)
|
||||
end
|
||||
|
||||
def audit_tags(**details)
|
||||
|
||||
@@ -9,6 +9,6 @@ class Kamal::Commands::Hook < Kamal::Commands::Base
|
||||
|
||||
private
|
||||
def hook_file(hook)
|
||||
"#{config.hooks_path}/#{hook}"
|
||||
File.join(config.hooks_path, hook)
|
||||
end
|
||||
end
|
||||
|
||||
@@ -222,7 +222,7 @@ class Kamal::Configuration
|
||||
|
||||
|
||||
def host_env_directory
|
||||
"#{run_directory}/env"
|
||||
File.join(run_directory, "env")
|
||||
end
|
||||
|
||||
def env
|
||||
|
||||
@@ -134,7 +134,7 @@ class Kamal::Configuration::Accessory
|
||||
end
|
||||
|
||||
def expand_host_path(host_path)
|
||||
absolute_path?(host_path) ? host_path : "#{service_data_directory}/#{host_path}"
|
||||
absolute_path?(host_path) ? host_path : File.join(service_data_directory, host_path)
|
||||
end
|
||||
|
||||
def absolute_path?(path)
|
||||
|
||||
Reference in New Issue
Block a user