<commit_before>require "git_timelog/version"
require "git_formatter"
require "json"

module GitTimelog
  # TODO: make the time changeable
  def git_timelog(from_time = '6am')
    `git log --pretty=format:"git__title:%sgit__description:%bgit__date:%cd" --author="#{current_author}" --since={#{from_time}} --reverse`
  end

  def current_author
    `git config user.name`
  end

  def json_format
    data = git_timelog
    gf = GitFormatter.new(data)
    gf.json_formatted.to_json
  end

  # list_style = 'ordered' || 'unordered'
  def to_clipboard(list_style = 'ordered')
    data = git_timelog
    gf = GitFormatter.new(data)
    `echo "#{gf.title_list(list_style)}" | pbcopy`
  end
end
<commit_msg>commit messages throughout the branch [0.5]<commit_after>require "git_timelog/version"
require "git_formatter"
require "json"

module GitTimelog
  # TODO: make the time changeable
  def git_timelog(from_time = '6am')
    `git log --pretty=format:"git__title:%sgit__description:%bgit__date:%cd" --author="#{current_author}" --since={#{from_time}} --reverse --all`
  end

  def current_author
    `git config user.name`
  end

  def json_format
    data = git_timelog
    gf = GitFormatter.new(data)
    gf.json_formatted.to_json
  end

  # list_style = 'ordered' || 'unordered'
  def to_clipboard(list_style = 'ordered')
    data = git_timelog
    gf = GitFormatter.new(data)
    `echo "#{gf.title_list(list_style)}" | pbcopy`
  end
end

{'fraction_non_alphanumeric': 0.12604456824512536, 'fraction_numerical': 0.002785515320334262, 'mean_word_length': 4.169064748201439, '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': '6299468', 'n_tokens_mistral': 525, 'n_tokens_neox': 510, 'n_words': 110}