Module: Byebug::Helpers::PathHelper

Included in:
Context, RestartCommand
Defined in:
lib/byebug/helpers/path.rb

Overview

Utilities for managing gem paths

Instance Method Summary collapse

Instance Method Details

#all_filesObject



31
32
33
# File 'lib/byebug/helpers/path.rb', line 31

def all_files
  @all_files ||= gem_files + test_files
end

#bin_fileObject



7
8
9
# File 'lib/byebug/helpers/path.rb', line 7

def bin_file
  @bin_file ||= Gem.bin_path('byebug', 'byebug')
end

#ext_filesObject



19
20
21
# File 'lib/byebug/helpers/path.rb', line 19

def ext_files
  @ext_files ||= expand_from_root('ext/**/*.{c,h,rb}')
end

#gem_filesObject



27
28
29
# File 'lib/byebug/helpers/path.rb', line 27

def gem_files
  @gem_files ||= [bin_file] + lib_files + ext_files
end

#lib_filesObject



15
16
17
# File 'lib/byebug/helpers/path.rb', line 15

def lib_files
  @lib_files ||= expand_from_root('lib/**/*.{rb,yml}')
end

#root_pathObject



11
12
13
# File 'lib/byebug/helpers/path.rb', line 11

def root_path
  @root_path ||= File.expand_path('../..', bin_file)
end

#test_filesObject



23
24
25
# File 'lib/byebug/helpers/path.rb', line 23

def test_files
  @test_files ||= expand_from_root('test/**/*.rb')
end