Module: Exercism::Rb::Config
- Defined in:
- lib/exercism/rb/config.rb
Class Method Summary collapse
Class Method Details
.editor ⇒ Object
20 21 22 |
# File 'lib/exercism/rb/config.rb', line 20 def editor ENV["XRB_EDITOR"] || ENV["VISUAL"] || ENV["EDITOR"] || "nvim" end |
.root(track_name = track) ⇒ Object
12 13 14 |
# File 'lib/exercism/rb/config.rb', line 12 def root(track_name = track) File.(ENV.fetch("XRB_ROOT", File.join(Dir.home, "exercism", track_name))) end |
.state_path ⇒ Object
16 17 18 |
# File 'lib/exercism/rb/config.rb', line 16 def state_path File.(ENV.fetch("XRB_STATE", File.join(Dir.home, ".local", "state", "exercism-rb", "state.toml"))) end |
.track ⇒ Object
8 9 10 |
# File 'lib/exercism/rb/config.rb', line 8 def track ENV.fetch("XRB_TRACK", "ruby") end |