yaml 0.2.1 → 0.3.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 173972ebf3a985ecece1c627660d4d064aedcf85b25bbe3da707ab1cd9421581
4
- data.tar.gz: eff61885260395c8bb27b60c13f267c6d065dcd7e16218a11f0e69705a5355da
3
+ metadata.gz: 2dc49195cfce5604fb8c6ff7ff3265afcd1c67ebb9bad912452c6f0564179f36
4
+ data.tar.gz: 880779b8ddc77af8cd27ab60659a52051d0473306e35971c667d37bd8194f5c9
5
5
  SHA512:
6
- metadata.gz: 4e38d75d7ae6fc2a2acfb77dde60ba1f41ecaf5f6a023f1de18d97ce4689852dbb4f02171082bf92cf340cae4ff6d3e157901737e2caa7cd9945950dc97f46fb
7
- data.tar.gz: '0864745483a5368e93c888b4b1b619b2fc07c6339f255ae6a14f7b665c438c00524095247298fa411a9994f90f2eae84d2a2ae77a6870c1bda0bb800c9eb6f74'
6
+ metadata.gz: d60f0111093a28c23130dc2c1bfdf9e644a488caa2d10e993fbdad02bedc544c58b8667b1414948755e9c299b50eca1fe4638f69f4fe0a12376bfa486596b597
7
+ data.tar.gz: 96854fbcb9435f9e0bb95d873fed77af878783f984385ca73dde1267d10d38ea29ba43b2fa51f1f9ce37a7dc40194492d2028e9e2c5d31b2bbef2ffe261565be
@@ -3,19 +3,27 @@ name: ubuntu
3
3
  on: [push, pull_request]
4
4
 
5
5
  jobs:
6
- build:
6
+ ruby-versions:
7
+ uses: ruby/actions/.github/workflows/ruby_versions.yml@master
8
+ with:
9
+ engine: cruby
10
+ min_version: 2.4
11
+
12
+ test:
13
+ needs: ruby-versions
7
14
  name: build (${{ matrix.ruby }} / ${{ matrix.os }})
8
15
  strategy:
9
16
  matrix:
10
- ruby: [ '3.0', 2.7, 2.6, 2.5, 2.4, head ]
17
+ ruby: ${{ fromJson(needs.ruby-versions.outputs.versions) }}
11
18
  os: [ ubuntu-latest, macos-latest ]
12
19
  runs-on: ${{ matrix.os }}
13
20
  steps:
14
- - uses: actions/checkout@v3.1.0
21
+ - uses: actions/checkout@v4.1.1
15
22
  - name: Set up Ruby
16
23
  uses: ruby/setup-ruby@v1
17
24
  with:
18
25
  ruby-version: ${{ matrix.ruby }}
19
- bundler-cache: true
26
+ - name: Install dependencies
27
+ run: bundle install --jobs 4 --retry 3
20
28
  - name: Run test
21
29
  run: bundle exec rake test
data/Gemfile CHANGED
@@ -4,9 +4,5 @@ group :development do
4
4
  gem "bundler"
5
5
  gem "rake"
6
6
  gem "test-unit"
7
-
8
- # Workaround for `unsafe_load`
9
- if "3.0" > RUBY_VERSION
10
- gem "psych", ">= 4.0"
11
- end
7
+ gem "test-unit-ruby-core"
12
8
  end
data/README.md CHANGED
@@ -38,7 +38,7 @@ YAML.dump("foo") # => "--- foo\n...\n"
38
38
  ```
39
39
 
40
40
  For detailed documentation, see
41
- [Psych](https://ruby-doc.org/stdlib/libdoc/psych/rdoc/index.html).
41
+ [Psych](https://ruby-doc.org/stdlib/exts/psych/Psych.html).
42
42
 
43
43
  ## Security
44
44
 
data/Rakefile CHANGED
@@ -7,11 +7,4 @@ Rake::TestTask.new(:test) do |t|
7
7
  t.test_files = FileList["test/**/test_*.rb"]
8
8
  end
9
9
 
10
- task :sync_tool do
11
- require 'fileutils'
12
- FileUtils.cp "../ruby/tool/lib/core_assertions.rb", "./test/lib"
13
- FileUtils.cp "../ruby/tool/lib/envutil.rb", "./test/lib"
14
- FileUtils.cp "../ruby/tool/lib/find_executable.rb", "./test/lib"
15
- end
16
-
17
10
  task :default => :test
data/lib/yaml/store.rb CHANGED
@@ -65,7 +65,7 @@ class YAML::Store < PStore
65
65
  end
66
66
 
67
67
  def load(content)
68
- table = YAML.unsafe_load(content)
68
+ table = YAML.respond_to?(:unsafe_load) ? YAML.unsafe_load(content) : YAML.load(content)
69
69
  if table == false
70
70
  {}
71
71
  else
data/lib/yaml.rb CHANGED
@@ -66,4 +66,5 @@ YAML = Psych # :nodoc:
66
66
  #
67
67
  # Syck can also be found on github: https://github.com/ruby/syck
68
68
  module YAML
69
+ LOADER_VERSION = "0.3.0"
69
70
  end
data/yaml.gemspec CHANGED
@@ -1,6 +1,13 @@
1
+ name = File.basename(__FILE__, ".gemspec")
2
+ version = ["lib", Array.new(name.count("-")+1, "..").join("/")].find do |dir|
3
+ break File.foreach(File.join(__dir__, dir, "#{name.tr('-', '/')}.rb")) do |line|
4
+ /^\s*LOADER_VERSION\s*=\s*"(.*)"/ =~ line and break $1
5
+ end rescue nil
6
+ end
7
+
1
8
  Gem::Specification.new do |spec|
2
- spec.name = "yaml"
3
- spec.version = "0.2.1"
9
+ spec.name = name
10
+ spec.version = version
4
11
  spec.authors = ["Aaron Patterson", "SHIBATA Hiroshi"]
5
12
  spec.email = ["aaron@tenderlovemaking.com", "hsbt@ruby-lang.org"]
6
13
 
@@ -15,7 +22,7 @@ Gem::Specification.new do |spec|
15
22
  # Specify which files should be added to the gem when it is released.
16
23
  # The `git ls-files -z` loads the files in the RubyGem that have been added into git.
17
24
  spec.files = Dir.chdir(File.expand_path('..', __FILE__)) do
18
- `git ls-files -z 2>/dev/null`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
25
+ `git ls-files -z 2>#{IO::NULL}`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
19
26
  end
20
27
  spec.bindir = "exe"
21
28
  spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: yaml
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Aaron Patterson
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: exe
11
11
  cert_chain: []
12
- date: 2022-12-05 00:00:00.000000000 Z
12
+ date: 2023-11-06 00:00:00.000000000 Z
13
13
  dependencies: []
14
14
  description: YAML Ain't Markup Language
15
15
  email:
@@ -54,7 +54,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
54
54
  - !ruby/object:Gem::Version
55
55
  version: '0'
56
56
  requirements: []
57
- rubygems_version: 3.4.0.dev
57
+ rubygems_version: 3.5.0.dev
58
58
  signing_key:
59
59
  specification_version: 4
60
60
  summary: YAML Ain't Markup Language