module FileUtils
def safe_ln(*args, **options)
Attempt to do a normal file link, but fall back to a copy if the link
def safe_ln(*args, **options) if LN_SUPPORTED[0] begin return options.empty? ? ln(*args) : ln(*args, **options) rescue StandardError, NotImplementedError LN_SUPPORTED[0] = false end end options.empty? ? cp(*args) : cp(*args, **options) end