<commit_before># essentially a "null" object
# useful for instatiating App objects
# with a router injected into it
class PathRouter
  def url_for(app: app_name)
    "#"
  end

  def path_for(app: app_name)
    app
  end
end
<commit_msg>fix path_router to impl expected router interface<commit_after># A special router to use to instantiate an OodApp
# object if all you have is the path to the app
class PathRouter
  attr_reader :category, :caption, :url, :type, :path

  def initialize(path)
    @caption = nil
    @category = "App"
    @url = "#"
    @type = :path
    @path = Pathname.new(path)
  end

  def owner
    @owner ||= Etc.getpwuid(path.stat.uid).name
  end
end

{'fraction_non_alphanumeric': 0.09171597633136094, 'fraction_numerical': 0.0, 'mean_word_length': 3.4834437086092715, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5795349', 'n_tokens_mistral': 229, 'n_tokens_neox': 224, 'n_words': 81}