Files
news.gitea.happylizard.me/bin/gems/facets-3.1.0/lib/standard/facets/pathname/to_path.rb
T
pizza2d1 4cee170d66
Gitea Actions Demo / Explore-Gitea-Actions (push) Failing after 9s
Add bin and edit workflow
2026-09-16 13:11:16 -06:00

29 lines
584 B
Ruby

# Unfortunately NilClass#to_path causes FileUtils to bomb when testing
# for symlinks. See issue #77. It would be better if Ruby could be changed
# so this would work. But until then we have no choice but to deprecate
# this method.
#class NilClass
# # Provide platform dependent null path.
# #
# # @standard
# # require 'facets/pathname'
# #
# # @author Daniel Burger
# def to_path
# Pathname.null
# end
#end
class Array
# Convert array to Pathname instance.
#
# @standard
# require 'facets/pathname'
#
def to_path
Pathname.new(join('/'))
end
end