Sha256: 4fe51adebac1e57b96265f6a5df5e68ba70fafca8cb7c6a21c6ebf260b30a2d5

Contents?: true

Size: 270 Bytes

Versions: 13

Compression:

Stored size: 270 Bytes

Contents

# This file provides a portable way to symlink, reverting to copy if symlinks are not supported.

FileUtils

if FileUtils.send(:fu_have_symlink?)
  class << FileUtils
    alias symlink_or_copy ln_s
  end
else
  class << FileUtils
    alias symlink_or_copy cp_r
  end
end

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
zena-1.2.1 lib/zena/core_ext/file_utils.rb
zena-1.2.0 lib/zena/core_ext/file_utils.rb
zena-1.1.3 lib/zena/core_ext/file_utils.rb
zena-1.1.2 lib/zena/core_ext/file_utils.rb
zena-1.1.1 lib/zena/core_ext/file_utils.rb
zena-1.1.0 lib/zena/core_ext/file_utils.rb
zena-1.0.0 lib/zena/core_ext/file_utils.rb
zena-1.0.0.rc3 lib/zena/core_ext/file_utils.rb
zena-1.0.0.rc2 lib/zena/core_ext/file_utils.rb
zena-1.0.0.rc1 lib/zena/core_ext/file_utils.rb
zena-1.0.0.beta3 lib/zena/core_ext/file_utils.rb
zena-1.0.0.beta2 lib/zena/core_ext/file_utils.rb
zena-1.0.0.beta1 lib/zena/core_ext/file_utils.rb