<commit_before>module Octopress
  module Ink
    module Plugins
      attr_reader :registered
      extend self

      @registered = false
      @plugins = []
      @user_plugins = []

      def theme
        @theme
      end

      def each(&block)
        plugins.each(&block)
      end

      # Store static files to be written
      #
      def static_files
        @static_files
      end

      def size
        plugins.size
      end

      def plugin(slug)
        if slug == 'theme'
          @theme
        else
          found = plugins.reject { |p| p.slug != slug }
          if found.empty?
            raise IOError.new "No Theme or Plugin with the slug '#{slug}' was found."
          end
          found.first
        end
      end

      def plugins
        [@theme].concat(@plugins).concat(@user_plugins).compact
      end

      def reset
        @registered = false
      end

      def register
        unless @registered
          @registered = true
          @static_files = []
          @css_tags = []
          @js_tags = []
          Cache.reset
          Bootstrap.reset
          PluginAssetPipeline.reset

          puts 'registering'
          plugins.each(&:register) 
        end
      end

      def add_files
        add_assets(%w{images pages files fonts docs})
        add_stylesheets<commit_msg>removed unnecessary puts<commit_after>module Octopress
  module Ink
    module Plugins
      attr_reader :registered
      extend self

      @registered = false
      @plugins = []
      @user_plugins = []

      def theme
        @theme
      end

      def each(&block)
        plugins.each(&block)
      end

      # Store static files to be written
      #
      def static_files
        @static_files
      end

      def size
        plugins.size
      end

      def plugin(slug)
        if slug == 'theme'
          @theme
        else
          found = plugins.reject { |p| p.slug != slug }
          if found.empty?
            raise IOError.new "No Theme or Plugin with the slug '#{slug}' was found."
          end
          found.first
        end
      end

      def plugins
        [@theme].concat(@plugins).concat(@user_plugins).compact
      end

      def reset
        @registered = false
      end

      def register
        unless @registered
          @registered = true
          @static_files = []
          @css_tags = []
          @js_tags = []
          Cache.reset
          Bootstrap.reset
          PluginAssetPipeline.reset

          plugins.each(&:register) 
        end
      end

      def add_files
        add_assets(%w{images pages files fonts docs})
        add_stylesheets
{'fraction_non_alphanumeric': 0.07331821617535904, 'fraction_numerical': 0.0, 'mean_word_length': 1.417351598173516, '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': '7561232', 'n_tokens_mistral': 738, 'n_tokens_neox': 691, 'n_words': 199}