<commit_before>#Our CLI Controller
require_relative 'scraper'
class FindYourZen::CLI

  def call
    FindYourZen::Zen.new.input_to_index(2)
    title
    intro
    menu
    start
  end

  def title
    puts "----------------------------------------"
    puts "[ > The eightfold path: 8 limbs of Yoga < ]"
    puts "----------------------------------------"
    puts ""
  end

  def intro
    Scraper.new.intro
  end

  def menu
    puts "The 8 limbs of yoga are:"
    puts ""
    puts "1. Yama"
    puts "2. Niyama"
    puts "3. Asana"
    puts "4. Pranayama"
    puts "5. Pratyahara"
    puts "6. Dharana"
    puts "7. Dhyana"
    puts "8. Samadhi"
    puts ""
  end

  def start
    puts "select a limb to learn more [enter a number 1-8]:"
    puts ""
    puts "<enter exit to end the program.>"
    puts ""
    input = gets.strip

    if input == "exit"
      puts ""
      puts "Namaste, <NAME>"
    elsif input.to_i > 8
      title
      menu
      start
    elsif input.to_i > 0
      index = input.to_i - 1
      print_info(index)

    else input.to_i == 0
      title
      menu
      start
    end
  end

  def print_details(input)
    puts ""
    puts "----------- #{zen.name} - #{zen.position} -----------"
    puts ""
    puts "quote"
    puts ""
    puts "---------------Description--------------"
    puts ""
    puts "#{zen.description}"
    puts ""
    puts "---------------Learn More--------------"
  end

  def print_info(index)
    puts Scraper.new.limbs_description[index]
  end


  def menu_options(input)

    puts ""
    puts "enter an option:"
    puts "[back] [next] [go to site] [exit]"
    puts ""

    input = gets.strip.downcase
    if input == "back"
      menu
    elsif input == "next"
      #method to go to next page, call it here
    elsif input == "go to site"
      #method that launches site
    elsif input == "exit"
      puts ""
      puts "Bye!"
    else
      puts "please enter one of the following:"       
    end
  end
  <commit_msg>#menu_options loop to work<commit_after>#Our CLI Controller
require_relative 'scraper'
class FindYourZen::CLI

  def call
    FindYourZen::Zen.new.input_to_index(2)
    title
    intro
    menu
    start
  end

  def title
    puts "----------------------------------------"
    puts "[ > The eightfold path: 8 limbs of Yoga < ]"
    puts "----------------------------------------"
    puts ""
  end

  def intro
    Scraper.new.intro
  end

  def menu
    puts "The 8 limbs of yoga are:"
    puts ""
    puts "1. Yama"
    puts "2. Niyama"
    puts "3. Asana"
    puts "4. Pranayama"
    puts "5. Pratyahara"
    puts "6. Dharana"
    puts "7. Dhyana"
    puts "8. Samadhi"
    puts ""
  end

  def start
    puts "select a limb to learn more [enter a number 1-8]:"
    puts ""
    puts "<enter exit to end the program.>"
    puts ""
    input = gets.strip

    if input == "exit"
      puts ""
      puts "Namaste, Jai Bhwagan"
    elsif input.to_i > 8
      title
      menu
      start
    elsif input.to_i > 0
      index = input.to_i - 1
      print_details(index)

    else input.to_i == 0
      title
      menu
      start
    end
  end

  def print_details(index)
    print_info(index)
    # puts "----------- #{zen.index} - #{zen.name} -----------"
    # puts ""
    # puts "quote"
    # puts ""
    # puts "---------------Description--------------"
    # puts ""
    # puts "#{zen.description}"
    # puts ""
    puts "---------------Learn More--------------"
    puts ""
    menu_options
    puts ""
  end

  def print_info(index)
    puts Scraper.new.limbs_description[index]
  end


  def menu_options
    puts ""
    puts "enter an option:"
    puts "[back] [more] [go to site] [exit]"
    puts ""

    input = gets.strip.downcase
    if input == "back"
      title
      menu
      start
    elsif input == "more"
      #method to go to more page, call it here
    elsif input == "go to site"
      #method that launches site
    elsif input == "exit"
      puts ""
      puts "Namaste!"
    else
      puts "please enter one of the following:"       
    end
  end
  
{'fraction_non_alphanumeric': 0.17441574415744157, 'fraction_numerical': 0.008364083640836408, 'mean_word_length': 1.5098765432098766, 'pattern_counts': {'":': 0, '<': 8, '<?xml version=': 0, '>': 12, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1426866', 'n_tokens_mistral': 1360, 'n_tokens_neox': 1362, 'n_words': 417}