Sha256: f330c6c884cf6053e63accbd3205ac473cfe53a1e8d8f1c0e20eccc51a03c2ea

Contents?: true

Size: 288 Bytes

Versions: 56

Compression:

Stored size: 288 Bytes

Contents

# frozen_string_literal: true

module Renalware
  module UsingTempFolder
    extend ActiveSupport::Concern

    def in_a_temporary_folder
      Dir.mktmpdir(nil, Rails.root.join("tmp").to_s) do |dir|
        yield Pathname(dir)
        # temp dir removed here
      end
    end
  end
end

Version data entries

56 entries across 56 versions & 1 rubygems

Version Path
renalware-core-2.1.1 app/models/concerns/renalware/using_temp_folder.rb
renalware-core-2.1.0 app/models/concerns/renalware/using_temp_folder.rb
renalware-core-2.0.167 app/models/concerns/renalware/using_temp_folder.rb
renalware-core-2.0.166 app/models/concerns/renalware/using_temp_folder.rb
renalware-core-2.0.165 app/models/concerns/renalware/using_temp_folder.rb
renalware-core-2.0.164 app/models/concerns/renalware/using_temp_folder.rb
renalware-core-2.0.163 app/models/concerns/renalware/using_temp_folder.rb
renalware-core-2.0.162 app/models/concerns/renalware/using_temp_folder.rb
renalware-core-2.0.161 app/models/concerns/renalware/using_temp_folder.rb
renalware-core-2.0.160 app/models/concerns/renalware/using_temp_folder.rb
renalware-core-2.0.159 app/models/concerns/renalware/using_temp_folder.rb
renalware-core-2.0.158 app/models/concerns/renalware/using_temp_folder.rb
renalware-core-2.0.157 app/models/concerns/renalware/using_temp_folder.rb
renalware-core-2.0.156 app/models/concerns/renalware/using_temp_folder.rb
renalware-core-2.0.155 app/models/concerns/renalware/using_temp_folder.rb
renalware-core-2.0.153 app/models/concerns/renalware/using_temp_folder.rb
renalware-core-2.0.152 app/models/concerns/renalware/using_temp_folder.rb
renalware-core-2.0.151 app/models/concerns/renalware/using_temp_folder.rb
renalware-core-2.0.149 app/models/concerns/renalware/using_temp_folder.rb
renalware-core-2.0.148 app/models/concerns/renalware/using_temp_folder.rb