Module: Sevgi::Function
- Defined in:
- lib/sevgi/function.rb,
lib/sevgi/function/ui.rb,
lib/sevgi/function/file.rb,
lib/sevgi/function/math.rb,
lib/sevgi/function/color.rb,
lib/sevgi/function/shell.rb,
lib/sevgi/function/locate.rb,
lib/sevgi/function/string.rb,
lib/sevgi/function/version.rb
Overview
Shared helper namespace used directly as Sevgi::Function and through F.
Defined Under Namespace
Modules: Color, File, Math, Pluralize, Shell, String, UI Classes: Locate
Constant Summary collapse
- VERSION =
Current version of the Sevgi function gem.
"0.93.1"
Constants included from Math
Constants included from Pluralize
Pluralize::IRREGULARS, Pluralize::PLURALS, Pluralize::RULES, Pluralize::UNCOUNTABLES
Class Method Summary collapse
-
.locate(filename, start, exclude: nil, extension: EXTENSION) ⇒ Sevgi::Function::Locate::Location
Locates a Sevgi-related file by walking upward from a start directory.
Methods included from UI
Methods included from File
changed?, existing, existing!, existing_map, existing_map!, out, qualify, subext, touch
Methods included from Math
acos, acot, approx, asin, atan, atan2, cos, cot, count, eq?, ge?, gt?, le?, lt?, precision, precision=, round, sin, tan, to_degrees, to_radians, with_precision, zero?
Methods included from Color
blue, bold, cyan, dim, green, magenta, red, yellow
Methods included from Shell
executable!, executable?, sh, sh!
Methods included from String
Methods included from Pluralize
Class Method Details
.locate(filename, start, exclude: nil, extension: EXTENSION) ⇒ Sevgi::Function::Locate::Location
Locates a Sevgi-related file by walking upward from a start directory.
83 84 85 86 87 |
# File 'lib/sevgi/function/locate.rb', line 83 def self.locate(filename, start, exclude: nil, extension: EXTENSION) Locate.(F.qualify(filename, extension), start, exclude:).tap do |path| Error.("Cannot load a file matching: #{filename}") unless path end end |