Sha256: 4a170600f0ae0033e4abac0f2468b7446f2a50060924721df28446551729c2ee

Contents?: true

Size: 1.37 KB

Versions: 2

Compression:

Stored size: 1.37 KB

Contents

module AgileUtils
  # Store the options that will be shared by many CLI classes
  module Options
    BASE_DIR = [
      :base_dir,
      { type: :string,
        aliases: '-b',
        desc: 'Base directory',
        default: Dir.pwd }
    ]

    EXTS = [
      :exts,
      { type: :array,
        aliases: '-e',
        desc: 'List of extensions to search for',
        default: [] }
    ]

    NON_EXTS = [
      :non_exts,
      { type: :array,
        aliases: '-f',
        desc: 'List of files without extension to search for',
        default: [] }
    ]

    INC_WORDS = [
      :inc_words,
      { type: :array,
        aliases: '-n',
        desc: 'List of words to be included in the result if any',
        default: [] }
    ]

    EXC_WORDS = [
      :exc_words,
      { type: :array,
        aliases: '-x',
        desc: 'List of words to be excluded from the result if any',
        default: [] }
    ]

    IGNORE_CASE = [
      :ignore_case,
      { type: :boolean,
        aliases: '-i',
        desc: 'Match case insensitively',
        default: true }
    ]

    RECURSIVE = [
      :recursive,
      { type: :boolean,
        aliases: '-r',
        desc: 'Search for files recursively',
        default: true }
    ]

    VERSION = [
      :version,
      { type: :boolean,
        aliases: '-v',
        desc: 'Display version information',
        default: false }
    ]
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
agile_utils-0.1.1 lib/agile_utils/base_option.rb
agile_utils-0.1.0 lib/agile_utils/base_option.rb