class Exercise::Path

Attributes

full[R]
project_root[R]

Public Class Methods

new(full_path, project_root) click to toggle source
# File lib/commands/exercise/command.rb, line 28
def initialize(full_path, project_root)
  @full = full_path
  @project_root = project_root
end

Public Instance Methods

relative() click to toggle source
# File lib/commands/exercise/command.rb, line 33
def relative
  ".#{File.expand_path(full).gsub(File.expand_path(project_root), '')}"
end