Sha256: 24d3c33448f1535d5c8b5bc2f2dce2075df07c771cb73e1a2f82b81f1dfb8796

Contents?: true

Size: 445 Bytes

Versions: 8

Compression:

Stored size: 445 Bytes

Contents

# frozen_string_literal: true

require "refinements/pathname"

module SublimeTextKit
  module Configuration
    # Models the settings.
    Model = Struct.new :project_roots, :metadata_dir, :snippets_format, :session_path, :user_dir do
      using Refinements::Pathname

      def project_dirs
        Array(project_roots).map { |path| Pathname(path).expand_path }
                            .flat_map(&:directories)
      end
    end
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
sublime_text_kit-17.6.0 lib/sublime_text_kit/configuration/model.rb
sublime_text_kit-17.5.0 lib/sublime_text_kit/configuration/model.rb
sublime_text_kit-17.4.0 lib/sublime_text_kit/configuration/model.rb
sublime_text_kit-17.3.0 lib/sublime_text_kit/configuration/model.rb
sublime_text_kit-17.2.0 lib/sublime_text_kit/configuration/model.rb
sublime_text_kit-17.1.0 lib/sublime_text_kit/configuration/model.rb
sublime_text_kit-17.0.1 lib/sublime_text_kit/configuration/model.rb
sublime_text_kit-17.0.0 lib/sublime_text_kit/configuration/model.rb