Class: PathParser

Inherits:
Object
  • Object
show all
Defined in:
lib/rstub/path_parser.rb

Overview

PathParser parses directory and file paths into a hash with directory and file arrays.

Instance Method Summary collapse

Instance Method Details

#get_globs(files) ⇒ Object



4
5
6
7
8
9
# File 'lib/rstub/path_parser.rb', line 4

def get_globs(files)
  glob_files = check_globs(files)
  directories = get_directories(glob_files)
  all_files = get_files_from_directory(glob_files, directories)
  { directories: directories, files: all_files.flatten.uniq }
end