<commit_before>require 'redmine_rubycas'
require 'account_controller_patch'
require 'setting_model_patch'

Redmine::Plugin.register :redmine_rubycas do
  name 'Redmine RubyCAS plugin'
  author '<NAME>'
  description 'This is a plugin for Redmine 2+ that integrates the RubyCAS client.'
  version '0.0.5'
  url 'https://github.com/brandonaaron/redmine_rubycas'
  author_url 'http://brandonaaron.net/'

  requires_redmine :version_or_higher => '2.2.2'

  menu(:account_menu, :login_without_cas, { :controller => "account", :action => "login_without_cas" },
    :caption => :login_without_cas, :after => :login,
    :if => Proc.new { RedmineRubyCas.enabled? && RedmineRubyCas.setting("maintain_standard_login") == "true" && !User.current.logged? })

  settings(:partial => 'settings/redmine_rubycas_settings', :default => {
    # plugin settings
    :enabled => false,
    :maintain_standard_login => true,
    :auto_create_users => false,
    :auto_update_users => false,
    :auto_user_attributes_map => 'firstname=firstName&lastname=lastName&mail=mail',
    :logout_of_cas_on_logout => true,
    # cas client config settings
    :base_url => "https://cas.yourcasserver.com",
    :login_url => nil,
    :logout_url => nil,
    :validate_url => nil,
    :username_session_key => 'cas_user',
    :extra_attributes_session_key => 'cas_extra_attributes'
  })
end

ActionDispatch::Callbacks.to_prepare do
  require_dependency 'account_controller'
  require_dependency 'setting'
  AccountController.send(:include, AccountControllerPatch)
  Setting.send(:include, SettingModelPatch)

  RedmineRubyCas.configure!
end
<commit_msg>Bump version to 0.0.6<commit_after>require 'redmine_rubycas'
require 'account_controller_patch'
require 'setting_model_patch'

Redmine::Plugin.register :redmine_rubycas do
  name 'Redmine RubyCAS plugin'
  author '<NAME>'
  description 'This is a plugin for Redmine 2+ that integrates the RubyCAS client.'
  version '0.0.6'
  url 'https://github.com/brandonaaron/redmine_rubycas'
  author_url 'http://brandonaaron.net/'

  requires_redmine :version_or_higher => '2.2.2'

  menu(:account_menu, :login_without_cas, { :controller => "account", :action => "login_without_cas" },
    :caption => :login_without_cas, :after => :login,
    :if => Proc.new { RedmineRubyCas.enabled? && RedmineRubyCas.setting("maintain_standard_login") == "true" && !User.current.logged? })

  settings(:partial => 'settings/redmine_rubycas_settings', :default => {
    # plugin settings
    :enabled => false,
    :maintain_standard_login => true,
    :auto_create_users => false,
    :auto_update_users => false,
    :auto_user_attributes_map => 'firstname=firstName&lastname=lastName&mail=mail',
    :logout_of_cas_on_logout => true,
    # cas client config settings
    :base_url => "https://cas.yourcasserver.com",
    :login_url => nil,
    :logout_url => nil,
    :validate_url => nil,
    :username_session_key => 'cas_user',
    :extra_attributes_session_key => 'cas_extra_attributes'
  })
end

ActionDispatch::Callbacks.to_prepare do
  require_dependency 'account_controller'
  require_dependency 'setting'
  AccountController.send(:include, AccountControllerPatch)
  Setting.send(:include, SettingModelPatch)

  RedmineRubyCas.configure!
end

{'fraction_non_alphanumeric': 0.12623152709359606, 'fraction_numerical': 0.005233990147783251, 'mean_word_length': 5.200381679389313, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 45, 'https://': 4, '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': '3410385', 'n_tokens_mistral': 1094, 'n_tokens_neox': 1042, 'n_words': 201}