Method: ShellHelpers::PathnameExt::Base#abs_path

Defined in:
lib/shell_helpers/pathname.rb

#abs_path(base: self.class.pwd, mode: :clean) ⇒ Object



205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
# File 'lib/shell_helpers/pathname.rb', line 205

def abs_path(base: self.class.pwd, mode: :clean)
	f= absolute? ? self : base+self
	case mode
	when :clean
		f.cleanpath
	when :clean_sym
		f.cleanpath(consider_symlink: true)
	when :real
		f.realpath
	when :realdir
		f.realdirpath
	else
		f
	end
end