タグ

ブックマーク / github.com/taichi-ishitani (1)

  • GitHub - taichi-ishitani/rupkl: Pkl parser for Ruby

    require 'rupkl' pkl = <<~'PKL' // From: // https://pkl-lang.org/main/current/language-tutorial/01_basic_config.html name = "Pkl: Configure your Systems in New Ways" attendants = 100 isInteractive = true amountLearned = 13.37 PKL RuPkl.load(pkl) # => # {:name=>"Pkl:Configure your Systems in New Ways", # :attendants=>100, # :isInteractive=>true, # :amountLearned=>13.37} File.open('sample.pkl', 'w')

    GitHub - taichi-ishitani/rupkl: Pkl parser for Ruby
    YassLab
    YassLab 2024/04/05
    “You can use the methods below to load a Pkl code into a Ruby structure: ... / RuPkl.load Load the given Pkl code into a Ruby structure / RuPkl.load_file Load a Pkl code read from the given file path into a Ruby structure ”
  • 1