class Locca::ProjectDirLocator
Public Instance Methods
config_path(project_dir)
click to toggle source
# File lib/locca/projects/project_dir_locator.rb, line 48 def config_path(project_dir) return File.join(project_dir, '.locca/config') end
locate(dir)
click to toggle source
# File lib/locca/projects/project_dir_locator.rb, line 28 def locate(dir) if not File.directory?(dir) return nil end while dir if File.directory?(File.join(dir, ".locca")) return dir end new_dir = File.expand_path('..', dir) if new_dir == dir break end dir = new_dir end return nil end