require 'yaml' hash = {1 => 'sqlite3', 2 => 'postgresql', 3 => 'mssql', 4 => 'mysql', 5 => 'oracle'} # write yaml file File.open("/home/user002/data.yaml", "wb") {|f| YAML.dump(hash, f) } # read yaml file data = YAML.load_file("/home/user002/data.yaml", "rb")
用户登录
还没有账号?立即注册
用户注册
投稿取消
文章分类: |
|
还能输入300字
上传中....