content stringlengths 1 103k ⌀ | path stringlengths 8 216 | filename stringlengths 2 179 | language stringclasses 15
values | size_bytes int64 2 189k | quality_score float64 0.5 0.95 | complexity float64 0 1 | documentation_ratio float64 0 1 | repository stringclasses 5
values | stars int64 0 1k | created_date stringdate 2023-07-10 19:21:08 2025-07-09 19:11:45 | license stringclasses 4
values | is_test bool 2
classes | file_hash stringlengths 32 32 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
prelude: |\n module AR; end\n class AR::Base\n def create_or_update\n nil\n end\n def save\n create_or_update\n end\n end\n class Foo < AR::Base; end\n class Bar < AR::Base; end\n o1 = Foo.new\n o2 = Bar.new\nbenchmark:\n vm_poly_same_method: |\n o1.save; o2.save;\n o1.save; o2.save;\n o1.save; o2.save;\n o1.save; o2.save;\n o1.save; o2.save;\n o1.save; o2.save;\n o1.save; o2.save;\n o1.save; o2.save;\nloop_count: 6000000\n | dataset_sample\yaml\ruby\vm_poly_same_method.yml | vm_poly_same_method.yml | YAML | 456 | 0.85 | 0.2 | 0 | awesome-app | 930 | 2023-12-22T07:57:08.883672 | MIT | false | d1ca3d640cd500631e4e0256bfcf5c4f |
# loop_count is not utilized since `i` is involved in the script\nbenchmark:\n vm_poly_singleton: |\n class C1\n def m; 1; end\n end\n\n o1 = C1.new\n o2 = C1.new\n o2.singleton_class\n\n i = 0\n while i<6_000_000 # benchmark loop 2\n o = (i % 2 == 0) ? o1 : o2\n o.m; o.m; o.m; o.m; o.m; o.m; o.m; o.m\n i += 1\n end\nloop_count: 1\n | dataset_sample\yaml\ruby\vm_poly_singleton.yml | vm_poly_singleton.yml | YAML | 361 | 0.95 | 0.166667 | 0.0625 | vue-tools | 61 | 2023-07-16T21:32:29.659527 | Apache-2.0 | false | c00533842be435d8a94d2502668c0eef |
prelude: |\n def m &b\n b\n end\n\n pr = m{\n a = 1\n }\nbenchmark:\n vm_proc: |\n pr.call\nloop_count: 6000000\n | dataset_sample\yaml\ruby\vm_proc.yml | vm_proc.yml | YAML | 115 | 0.85 | 0.083333 | 0 | awesome-app | 37 | 2024-12-13T23:26:06.362085 | Apache-2.0 | false | 355852360e0b63582989934d95e22671 |
prelude: |\n def rec n\n if n > 0\n rec n-1\n else\n raise\n end\n end\nbenchmark:\n vm_raise1: |\n begin\n rec 1\n rescue\n # ignore\n end\nloop_count: 6000000\n | dataset_sample\yaml\ruby\vm_raise1.yml | vm_raise1.yml | YAML | 187 | 0.95 | 0.125 | 0.0625 | react-lib | 249 | 2025-03-02T09:02:00.315702 | MIT | false | 93161e717e9c0fcdde877646f3aa0203 |
prelude: |\n def rec n\n if n > 0\n rec n-1\n else\n raise\n end\n end\nbenchmark:\n vm_raise2: |\n begin\n rec 10\n rescue\n # ignore\n end\nloop_count: 6000000\n | dataset_sample\yaml\ruby\vm_raise2.yml | vm_raise2.yml | YAML | 188 | 0.95 | 0.125 | 0.0625 | awesome-app | 142 | 2025-04-22T17:44:14.532580 | MIT | false | 70b25e30afdd01b77454ea4b700ea037 |
prelude: |\n str = 'xxxhogexxx'\nbenchmark:\n vm_regexp: |\n /hoge/ =~ str\n vm_regexp_invert: |\n str =~ /hoge/\nloop_count: 6000000\n | dataset_sample\yaml\ruby\vm_regexp.yml | vm_regexp.yml | YAML | 136 | 0.7 | 0 | 0 | python-kit | 68 | 2024-03-27T21:47:07.017525 | BSD-3-Clause | false | 21a37a093de636135a9f98db4a82814b |
prelude: |\n class C\n def m\n end\n end\n\n o = C.new\n m = :m\nbenchmark:\n vm_send: |\n o.__send__ :m\n vm_send_var: |\n o.__send__ m\nloop_count: 6000000\n | dataset_sample\yaml\ruby\vm_send.yml | vm_send.yml | YAML | 163 | 0.85 | 0.142857 | 0 | awesome-app | 663 | 2023-11-16T08:12:09.308924 | MIT | false | af52669d442c4ad6a628c2912cb587b8 |
prelude: |\n ary = []\n kw = {a: 1}\n empty_kw = {}\n kw_ary = [Hash.ruby2_keywords_hash(a: 1)]\n empty_kw_ary = [Hash.ruby2_keywords_hash({})]\nbenchmark:\n vm_send_cfunc: itself\n vm_send_cfunc_splat: itself(*ary)\n vm_send_cfunc_splat_kw_hash: equal?(*kw_ary)\n vm_send_cfunc_splat_empty_kw_hash: itself(*empty_kw_ary)\n vm_send_cfunc_splat_kw: equal?(*ary, **kw)\n vm_send_cfunc_splat_empty_kw: itself(*ary, **empty_kw)\nloop_count: 20000000\n | dataset_sample\yaml\ruby\vm_send_cfunc.yml | vm_send_cfunc.yml | YAML | 444 | 0.7 | 0 | 0 | node-utils | 676 | 2023-08-12T17:50:57.061519 | MIT | false | 47cd4fa68f10a9bc5db826dfc723b146 |
benchmark:\n vm_string_literal: |\n x = "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"\nloop_count: 6000000\n | dataset_sample\yaml\ruby\vm_string_literal.yml | vm_string_literal.yml | YAML | 128 | 0.7 | 0 | 0 | awesome-app | 411 | 2023-12-18T23:52:11.367423 | BSD-3-Clause | false | 6df56fa0ffec678891593923a1e70970 |
prelude: |\n s = Struct.new(*('a'..'z').map { |x| x.to_sym })\n x = s.new\nbenchmark:\n vm_struct_big_aref_hi: |\n x.z # x[25]\nloop_count: 6000000\n | dataset_sample\yaml\ruby\vm_struct_big_aref_hi.yml | vm_struct_big_aref_hi.yml | YAML | 148 | 0.8 | 0 | 0 | vue-tools | 677 | 2024-12-30T16:38:14.476809 | BSD-3-Clause | false | 3eff3db36e2c29e0cad3111a9d8f285a |
prelude: |\n s = Struct.new(*('a'..'z').map { |x| x.to_sym })\n x = s.new\nbenchmark:\n vm_struct_big_aref_lo: |\n x.k # x[10]\nloop_count: 6000000\n | dataset_sample\yaml\ruby\vm_struct_big_aref_lo.yml | vm_struct_big_aref_lo.yml | YAML | 148 | 0.8 | 0 | 0 | vue-tools | 323 | 2024-08-24T23:58:57.976650 | BSD-3-Clause | false | 3cf50fbd3704e62c044dd12f158feaf3 |
# loop_count is not utilized since `i` is involved in the script\nbenchmark:\n vm_struct_big_aset: |\n s = Struct.new(*('a'..'z').map { |x| x.to_sym })\n x = s.new\n i = 0\n while i<6_000_000\n i += 1\n x.k = i # x[10] = i\n end\nloop_count: 1\n | dataset_sample\yaml\ruby\vm_struct_big_aset.yml | vm_struct_big_aset.yml | YAML | 260 | 0.8 | 0.090909 | 0.090909 | node-utils | 523 | 2023-12-20T06:38:16.380305 | MIT | false | 660ee098ee1f13433978d428967256e3 |
prelude: |\n s = Struct.new(*('a'..'z').map { |x| x.to_sym })\n x = s.new\nbenchmark:\n vm_struct_big_href_hi: |\n x[:z]\nloop_count: 6000000\n | dataset_sample\yaml\ruby\vm_struct_big_href_hi.yml | vm_struct_big_href_hi.yml | YAML | 142 | 0.7 | 0 | 0 | python-kit | 118 | 2023-10-09T05:48:17.416902 | BSD-3-Clause | false | 2701c96dcde8822aba682f0710988bf4 |
prelude: |\n s = Struct.new(*('a'..'z').map { |x| x.to_sym })\n x = s.new\nbenchmark:\n vm_struct_big_href_lo: |\n x[:k]\nloop_count: 6000000\n | dataset_sample\yaml\ruby\vm_struct_big_href_lo.yml | vm_struct_big_href_lo.yml | YAML | 142 | 0.7 | 0 | 0 | python-kit | 962 | 2024-10-25T13:16:01.742489 | GPL-3.0 | false | f48c17cb336f77f47712e214444520e5 |
# loop_count is not utilized since `i` is involved in the script\nbenchmark:\n vm_struct_big_hset: |\n s = Struct.new(*('a'..'z').map { |x| x.to_sym })\n x = s.new\n i = 0\n while i<6_000_000\n i += 1\n x[:k] = i\n end\nloop_count: 1\n | dataset_sample\yaml\ruby\vm_struct_big_hset.yml | vm_struct_big_hset.yml | YAML | 250 | 0.8 | 0.090909 | 0.090909 | node-utils | 542 | 2023-09-26T10:57:12.836395 | MIT | false | bcd2858491ecee725d51b1cb9ab4394f |
prelude: |\n s = Struct.new(:a, :b, :c)\n x = s.new\nbenchmark:\n vm_struct_small_aref: |\n x.a\nloop_count: 6000000\n | dataset_sample\yaml\ruby\vm_struct_small_aref.yml | vm_struct_small_aref.yml | YAML | 117 | 0.7 | 0 | 0 | awesome-app | 412 | 2023-12-01T09:57:22.718057 | MIT | false | 486ba1a88db0d90385967003543561dd |
# loop_count is not utilized since `i` is involved in the script\nbenchmark:\n vm_struct_small_aset: |\n s = Struct.new(:a, :b, :c)\n x = s.new\n i = 0\n while i<6_000_000\n i += 1\n x.a = i\n end\nloop_count: 1\n | dataset_sample\yaml\ruby\vm_struct_small_aset.yml | vm_struct_small_aset.yml | YAML | 228 | 0.8 | 0.090909 | 0.090909 | node-utils | 231 | 2023-12-26T18:52:53.047462 | BSD-3-Clause | false | 21cbd0b684d349a615efce2bd6af95e1 |
prelude: |\n s = Struct.new(:a, :b, :c)\n x = s.new\nbenchmark:\n vm_struct_small_href: |\n x[:a]\nloop_count: 6000000\n | dataset_sample\yaml\ruby\vm_struct_small_href.yml | vm_struct_small_href.yml | YAML | 119 | 0.7 | 0 | 0 | python-kit | 65 | 2024-05-09T05:37:32.397202 | BSD-3-Clause | false | b70527b888110060c9a5edc7b9d3e3b8 |
prelude: |\n s = Struct.new(:a, :b, :c)\n x = s.new\nbenchmark:\n vm_struct_small_hset: |\n x[:a] = 1\nloop_count: 6000000\n | dataset_sample\yaml\ruby\vm_struct_small_hset.yml | vm_struct_small_hset.yml | YAML | 123 | 0.7 | 0 | 0 | python-kit | 494 | 2024-03-25T06:35:36.751552 | GPL-3.0 | false | a01c0ad14600d2deb42f1712b0f1edb6 |
prelude: |\n class C\n def m\n 1\n end\n end\n\n class CC < C\n def m\n super()\n end\n end\n\n obj = CC.new\nbenchmark:\n vm_super: obj.m\nloop_count: 6000000\n | dataset_sample\yaml\ruby\vm_super.yml | vm_super.yml | YAML | 172 | 0.85 | 0.235294 | 0 | awesome-app | 474 | 2024-10-06T22:26:16.396860 | MIT | false | b41c473971285361b9da1bc3c1169aa6 |
prelude: |\n @a = [1].freeze\n @ea = [].freeze\n @kw = {y: 1}.freeze\n @b = lambda{}\n extend(Module.new{def arg_splat(x=0, y: 0) end})\n extend(Module.new{def arg_splat_block(x=0, y: 0) end})\n extend(Module.new{def splat_kw_splat(x=0, y: 0) end})\n extend(Module.new{def splat_kw_splat_block(x=0, y: 0) end})\n extend(Module.new{def splat_kw(x=0, y: 0) end})\n extend(Module.new{def splat_kw_block(x=0, y: 0) end})\n\n extend(Module.new{def arg_splat; super(1, *@ea) end})\n extend(Module.new{def arg_splat_block; super(1, *@ea, &@b) end})\n extend(Module.new{def splat_kw_splat; super(*@a, **@kw) end})\n extend(Module.new{def splat_kw_splat_block; super(*@a, **@kw, &@b) end})\n extend(Module.new{def splat_kw; super(*@a, y: 1) end})\n extend(Module.new{def splat_kw_block; super(*@a, y: 1, &@b) end})\nbenchmark:\n arg_splat: "arg_splat"\n arg_splat_block: "arg_splat_block"\n splat_kw_splat: "splat_kw_splat"\n splat_kw_splat_block: "splat_kw_splat_block"\n splat_kw: "splat_kw"\n splat_kw_block: "splat_kw_block"\n | dataset_sample\yaml\ruby\vm_super_splat_calls.yml | vm_super_splat_calls.yml | YAML | 1,018 | 0.85 | 0.48 | 0 | awesome-app | 287 | 2025-06-19T17:56:30.817804 | Apache-2.0 | false | 5721c41a646e0c4709187e69064016a9 |
benchmark:\n vm_thread_alive_check: |\n t = Thread.new{}\n while t.alive?\n Thread.pass\n end\nloop_count: 50_000\n\n | dataset_sample\yaml\ruby\vm_thread_alive_check.yml | vm_thread_alive_check.yml | YAML | 124 | 0.7 | 0.125 | 0 | python-kit | 531 | 2024-04-28T06:22:00.127226 | GPL-3.0 | false | f2a4db58ba9c086dfc4addf86d99066b |
# while loop cost is not removed due to benchmark_driver.gem's limitation\nbenchmark:\n vm_yield: |\n def m\n i = 0\n while i<30_000_000\n i += 1\n yield\n end\n end\n\n m{}\nloop_count: 1\n | dataset_sample\yaml\ruby\vm_yield.yml | vm_yield.yml | YAML | 216 | 0.95 | 0.230769 | 0.083333 | python-kit | 211 | 2023-10-19T23:05:59.172278 | MIT | false | 9868834be17dd35ee7074d8f6d25d689 |
prelude: |\n class C\n def m a\n 1\n end\n end\n\n class CC < C\n def m a\n super\n end\n end\n\n obj = CC.new\nbenchmark:\n vm_zsuper: |\n obj.m 10\nloop_count: 6000000\n | dataset_sample\yaml\ruby\vm_zsuper.yml | vm_zsuper.yml | YAML | 184 | 0.85 | 0.222222 | 0 | vue-tools | 214 | 2023-08-06T18:13:33.562219 | MIT | false | 05d936fa74a68acd1c2b72d61e5c9a7a |
prelude: |\n a = [1].freeze\n ea = [].freeze\n kw = {y: 1}.freeze\n b = lambda{}\n extend(Module.new{def arg_splat(x=0, y: 0) end})\n extend(Module.new{def arg_splat_block(x=0, y: 0) end})\n extend(Module.new{def arg_splat_post(x=0, y: 0) end})\n extend(Module.new{def splat_kw_splat(x=0, y: 0) end})\n extend(Module.new{def splat_kw_splat_block(x=0, y: 0) end})\n extend(Module.new{def splat_kw(x=0, y: 0) end})\n extend(Module.new{def splat_kw_block(x=0, y: 0) end})\n\n extend(Module.new{def arg_splat(x, *a) super end})\n extend(Module.new{def arg_splat_block(x, *a, &b) super end})\n extend(Module.new{def arg_splat_post(*a, x) super end})\n extend(Module.new{def splat_kw_splat(*a, **kw) super end})\n extend(Module.new{def splat_kw_splat_block(*a, **kw, &b) super end})\n extend(Module.new{def splat_kw(*a, y: 1) super end})\n extend(Module.new{def splat_kw_block(*a, y: 1, &b) super end})\nbenchmark:\n arg_splat: "arg_splat(1, *ea)"\n arg_splat_block: "arg_splat_block(1, *ea, &b)"\n arg_splat_post: "arg_splat_post(1, *ea, &b)"\n splat_kw_splat: "splat_kw_splat(*a, **kw)"\n splat_kw_splat_block: "splat_kw_splat_block(*a, **kw, &b)"\n splat_kw: "splat_kw(*a, y: 1)"\n splat_kw_block: "splat_kw_block(*a, y: 1, &b)"\n | dataset_sample\yaml\ruby\vm_zsuper_splat_calls.yml | vm_zsuper_splat_calls.yml | YAML | 1,224 | 0.85 | 0.5 | 0 | node-utils | 413 | 2023-09-22T15:50:57.738825 | Apache-2.0 | false | f5e59e0ba523f4b4270a93924cfe4ddb |
# Note: You must restart bin/webpack-dev-server for changes to take effect\n\ndefault: &default\n source_path: app/javascript\n source_entry_path: entrypoints\n public_root_path: public\n public_output_path: packs\n cache_path: tmp/cache/webpacker\n check_yarn_integrity: false\n webpack_compile_output: false\n\n # Additional paths webpack should lookup modules\n # ['app/assets', 'engine/foo/app/assets']\n resolved_paths: []\n\n # Cache manifest.json for performance\n cache_manifest: true\n\n # Extract and emit a css file\n extract_css: true\n\n static_assets_extensions:\n - .jpg\n - .jpeg\n - .png\n - .tiff\n - .ico\n - .svg\n - .eot\n - .otf\n - .ttf\n - .woff\n - .woff2\n\n extensions:\n - .mjs\n - .js\n - .jsx\n - .ts\n - .tsx\n - .sass\n - .scss\n - .css\n - .module.sass\n - .module.scss\n - .module.css\n - .png\n - .svg\n - .gif\n - .jpeg\n - .jpg\n\ndevelopment:\n <<: *default\n\n compile: true\n\n # Reload manifest in development environment so we pick up changes\n cache_manifest: false\n\n # Reference: https://webpack.js.org/configuration/dev-server/\n dev_server:\n https: false\n host: 0.0.0.0\n port: 3035\n public: localhost:3035\n hmr: false\n # Inline should be set to true if using HMR\n inline: true\n overlay: true\n compress: true\n disable_host_check: true\n use_local_ip: false\n quiet: false\n headers:\n 'Access-Control-Allow-Origin': '*'\n watch_options:\n ignored: '**/node_modules/**'\n\ntest:\n <<: *default\n\n # CI precompiles packs prior to running the tests.\n # Also avoids race conditions in parallel_tests.\n compile: false\n\n # Compile test packs to a separate directory\n public_output_path: packs-test\n\nproduction:\n <<: *default\n\n # Production depends on precompilation of packs prior to booting for performance.\n compile: false\n | dataset_sample\yaml\ruby\webpacker.yml | webpacker.yml | YAML | 1,859 | 0.8 | 0.042553 | 0.151899 | react-lib | 966 | 2024-05-31T03:07:17.201963 | Apache-2.0 | false | ec8408d16493c2fc37cee04102208efa |
# Additionally influences open graph metadata as part of jekyll-seo-tag, and the theme\ntitle: 'Metasploit Documentation | Penetration Testing Software, Pen Testing Security'\ndescription: View Metasploit Framework Documentation\nsearchTitle: Metasploit Documentation\nbaseurl: ''\nurl: 'https://rapid7.github.io/metasploit-framework'\nlogo: assets/images/favicon.png\n\n# Build settings\ntheme: just-the-docs\nplugins:\n - jekyll-sitemap\n - jekyll-seo-tag\n\ncompress_html:\n clippings: all\n comments: all\n endings: all\n startings: []\n blanklines: false\n profile: false\n ignore:\n envs: development\n\nexclude:\n - '*.rb'\n - 'build.rb'\n - metasploit-framework.wiki\n - metasploit-framework.wiki.old\n - README.md\n\n# just-the-docs config\nmermaid_enabled: true\nmermaid:\n version: "10.8.0"\nheading_anchors: true\naux_links_new_tab: true\naux_links:\n 'Metasploit Framework on GitHub':\n - '//github.com/rapid7/metasploit-framework'\n\nnav_cache: true\n\n# We set gh_edit_link to false to opt out of the default edit link support - and instead use a custom implementation in _includes/footer_custom.html\ngh_edit_link: false\ngh_edit_link_text: 'Edit this page on GitHub'\ngh_edit_repository: 'https://github.com/rapid7/metasploit-framework'\ngh_edit_branch: 'master'\ngh_edit_source: docs\ngh_edit_view_mode: 'tree'\n\nga_tracking: UA-4622520-7\nga_tracking_anonymize_ip: true\n\nfavicon: assets/images/favicon.png\n\nback_to_top: true\nback_to_top_text: 'Back to top'\n\njust_the_docs:\n collections: []\n\nignore_theme_config: true\n | dataset_sample\yaml\ruby\_config.yml | _config.yml | YAML | 1,508 | 0.8 | 0 | 0.076923 | react-lib | 448 | 2024-02-18T21:27:39.255996 | Apache-2.0 | false | 0790873a18ce1c5ebf7efaf525a07eaa |
# Staging assumes that it is currently deployed to gh-pages; All links are prefixed with /metasploit-framework\nbaseurl: 'metasploit-framework'\nga_tracking: ''\n | dataset_sample\yaml\ruby\_config_staging.yml | _config_staging.yml | YAML | 159 | 0.8 | 0 | 0.333333 | python-kit | 513 | 2024-10-28T20:32:33.908329 | BSD-3-Clause | false | b8f551173a505828fab3d1479ab42a55 |
# -*- YAML -*-\n# Copyright (C) 2011 Urabe, Shyouhei. All rights reserved.\n#\n# This file is a part of the programming language Ruby. Permission is hereby\n# granted, to either redistribute or modify this file, provided that the\n# conditions mentioned in the file COPYING are met. Consult the file for\n# details.\n\n# When you see Travis CI issues, or you are interested in understanding how to\n# manage, please check the link below.\n# https://github.com/ruby/ruby/wiki/CI-Servers#travis-ci\n\n# We enable Travis on the specific branches or forked repositories here.\n# https://docs.travis-ci.com/user/conditions-v1\nif: >-\n (fork OR branch = master OR branch =~ /^ruby_\d_\d$/)\n AND (commit_message !~ /(\[DOC\]|Document)/)\n AND NOT (type = 'push' AND sender =~ /\[bot\]/)\n\nlanguage: c\n\nos: linux\n\ndist: jammy\n\ngit:\n quiet: true\n\nenv:\n global:\n - NPROC="$(nproc)"\n - JOBS="-j${NPROC}"\n # https://github.com/travis-ci/travis-build/blob/e411371dda21430a60f61b8f3f57943d2fe4d344/lib/travis/build/bash/travis_apt_get_options.bash#L7\n - travis_apt_get_options='--allow-downgrades --allow-remove-essential --allow-change-held-packages'\n - travis_apt_get_options="-yq --no-install-suggests --no-install-recommends $travis_apt_get_options"\n # -g0 disables backtraces when SEGV. Do not set that.\n - debugflags=-ggdb3\n - RUBY_TESTOPTS="$JOBS -q --tty=no"\n\n.org.ruby-lang.ci.matrix-definitions:\n - &gcc-11\n compiler: gcc-11\n before_install:\n - tool/travis_retry.sh sudo bash -c "rm -rf '${TRAVIS_ROOT}/var/lib/apt/lists/'* && exec apt-get update -yq"\n - >-\n tool/travis_retry.sh sudo -E apt-get $travis_apt_get_options install\n gcc-11\n g++-11\n libffi-dev\n libncurses-dev\n libncursesw5-dev\n libreadline-dev\n libssl-dev\n libyaml-dev\n openssl\n zlib1g-dev\n - gcc-11 --version\n - &ppc64le-linux\n name: ppc64le-linux\n arch: ppc64le\n <<: *gcc-11\n - &s390x-linux\n name: s390x-linux\n arch: s390x\n <<: *gcc-11\n env:\n # Avoid possible test failures with the zlib applying the following patch\n # on s390x CPU architecture.\n # https://github.com/madler/zlib/pull/410\n - DFLTCC=0\n\nmatrix:\n include:\n - <<: *ppc64le-linux\n - <<: *s390x-linux\n allow_failures:\n - name: ppc64le-linux\n - name: s390x-linux\n fast_finish: true\n\nbefore_script:\n - lscpu\n - ./autogen.sh\n - mkdir build\n - cd build\n - ../configure -C --disable-install-doc --prefix=$(pwd)/install\n - make -s $JOBS\n - make -s $JOBS install\n # Useful info to report issues to the Ruby.\n - $(pwd)/install/bin/ruby -v\n # Useful info To report issues to the RubyGems.\n - $(pwd)/install/bin/gem env\n\nscript:\n - make -s test\n - ../tool/travis_wait.sh make -s test-all RUBYOPT="-w"\n - ../tool/travis_wait.sh make -s test-spec\n\n# We want to be notified when something happens.\nnotifications:\n webhooks:\n urls:\n # ruby-lang slack: ruby/simpler-alerts-bot (travis)\n - secure: mRsoS/UbqDkKkW5p3AEqM27d4SZnV6Gsylo3bm8T/deltQzTsGzZwrm7OIBXZv0UFZdE68XmPlyHfZFLSP2V9QZ7apXMf9/vw0GtcSe1gchtnjpAPF6lYBn7nMCbVPPx9cS0dwL927fjdRM1vj7IKZ2bk4F0lAJ25R25S6teqdk=\n on_success: never\n on_failure: always\n email:\n recipients:\n - jun.aruga@gmail.com\n on_success: never\n on_failure: always\n | dataset_sample\yaml\ruby_ruby\.travis.yml | .travis.yml | YAML | 3,337 | 0.8 | 0.018018 | 0.212121 | vue-tools | 331 | 2025-01-13T21:02:17.930046 | Apache-2.0 | false | b8a06cb0f448727de6bbc3f59a57da14 |
files:\n 'yjit*': [team:yjit]\n 'yjit/**/*': [team:yjit]\n 'yjit/src/cruby_bindings.inc.rs': []\n 'doc/yjit/*': [team:yjit]\n 'bootstraptest/test_yjit*': [team:yjit]\n 'test/ruby/test_yjit*': [team:yjit]\n 'zjit*': [team:yjit]\n 'zjit/**/*': [team:yjit]\n 'zjit/src/cruby_bindings.inc.rs': []\n 'doc/zjit*': [team:yjit]\n 'test/ruby/test_zjit*': [team:yjit]\noptions:\n ignore_draft: true\n # This currently doesn't work as intended. We want to skip reviews when only\n # cruby_bingings.inc.rs is modified, but this skips reviews even when other\n # yjit files are modified as well. To be enabled after fixing the behavior.\n #last_files_match_only: true\n | dataset_sample\yaml\ruby_ruby\.github\auto_request_review.yml | auto_request_review.yml | YAML | 654 | 0.8 | 0 | 0.222222 | python-kit | 659 | 2024-11-18T09:16:18.987032 | BSD-3-Clause | false | eb0cb65570bb532384df261a7be9632d |
version: 2\nupdates:\n - package-ecosystem: 'github-actions'\n directory: '/'\n schedule:\n interval: 'daily'\n - package-ecosystem: 'github-actions'\n directory: '/.github/actions/slack'\n schedule:\n interval: 'daily'\n - package-ecosystem: 'github-actions'\n directory: '/.github/actions/setup/directories'\n schedule:\n interval: 'daily'\n - package-ecosystem: 'cargo'\n directory: '/yjit'\n schedule:\n interval: 'daily'\n | dataset_sample\yaml\ruby_ruby\.github\dependabot.yml | dependabot.yml | YAML | 457 | 0.7 | 0 | 0 | vue-tools | 591 | 2024-01-13T06:57:12.711642 | MIT | false | f75001d1ce410ad42ec0bd11cf6789a3 |
Documentation:\n- changed-files:\n - all-globs-to-all-files: doc/**\n\nBackport:\n- base-branch: 'ruby_3_\d'\n | dataset_sample\yaml\ruby_ruby\.github\labeler.yml | labeler.yml | YAML | 105 | 0.8 | 0 | 0 | awesome-app | 447 | 2024-03-22T03:47:31.829285 | MIT | false | 54f51a0c26f6629d55238a3b5e1da80b |
name: Compiles ruby in a container\ndescription: >-\n Makes ruby using a dedicated container\n\ninputs:\n tag:\n required: false\n default: clang-18\n description: >-\n container image tag to use in this run.\n\n with_gcc:\n required: false\n description: >-\n override compiler path & flags.\n\n CFLAGS:\n required: false\n description: >-\n C compiler flags to override.\n\n CXXFLAGS:\n required: false\n description: >-\n C++ compiler flags to override.\n\n optflags:\n required: false\n # -O1 is faster than -O3 in our tests... Majority of time are consumed trying\n # to optimize binaries. Also GitHub Actions run on relatively modern CPUs\n # compared to, say, GCC 4 or Clang 3. We don't specify `-march=native`\n # because compilers tend not understand what the CPU is.\n default: '-O1'\n description: >-\n Compiler flags for optimisations.\n\n cppflags:\n required: false\n description: >-\n Additional preprocessor flags.\n\n append_configure:\n required: false\n default: >-\n --without-valgrind\n --without-jemalloc\n --without-gmp\n description: >-\n flags to append to configure.\n\n enable_shared:\n required: false\n default: true\n description: >-\n Whether to build libruby.so.\n\n check:\n required: false\n default: ''\n description: >-\n Whether to run `make check`\n\n mspecopt:\n required: false\n default: ''\n description: >-\n Additional options for mspec.\n\n static_exts:\n required: false\n description: >-\n whitespace separated list of extensions that need be linked statically.\n\nruns:\n using: composite\n steps:\n - shell: bash\n run: docker pull --quiet 'ghcr.io/ruby/ruby-ci-image:${{ inputs.tag }}'\n\n - name: Enable Launchable conditionally\n id: enable-launchable\n run: echo "enable-launchable=true" >> $GITHUB_OUTPUT\n shell: bash\n if: >-\n ${{\n github.repository == 'ruby/ruby' ||\n (github.repository != 'ruby/ruby' && env.LAUNCHABLE_TOKEN)\n }}\n\n - name: compile\n shell: bash\n run: >-\n docker run\n --rm\n --user=root\n --volume '${{ github.workspace }}:/github/workspace:ro'\n --workdir=/github/workspace\n --entrypoint=/github/workspace/.github/actions/compilers/entrypoint.sh\n --env CI\n --env GITHUB_ACTION\n --env INPUT_WITH_GCC='${{ inputs.with_gcc || inputs.tag }}'\n --env INPUT_CFLAGS='${{ inputs.CFLAGS }}'\n --env INPUT_CXXFLAGS='${{ inputs.CXXFLAGS }}'\n --env INPUT_OPTFLAGS='${{ inputs.OPTFLAGS }}'\n --env INPUT_CPPFLAGS='${{ inputs.cppflags }}'\n --env INPUT_APPEND_CONFIGURE='${{ inputs.append_configure }}'\n --env INPUT_CHECK='${{ inputs.check }}'\n --env INPUT_MSPECOPT='${{ inputs.mspecopt }}'\n --env INPUT_ENABLE_SHARED='${{ inputs.enable_shared }}'\n --env INPUT_STATIC_EXTS='${{ inputs.static_exts }}'\n --env LAUNCHABLE_ORGANIZATION='${{ github.repository_owner }}'\n --env LAUNCHABLE_WORKSPACE='${{ github.event.repository.name }}'\n --env LAUNCHABLE_ENABLED='${{ steps.enable-launchable.outputs.enable-launchable || false }}'\n --env GITHUB_PR_HEAD_SHA='${{ github.event.pull_request.head.sha || github.sha }}'\n --env GITHUB_PULL_REQUEST_URL='${{ github.event.pull_request.html_url }}'\n --env GITHUB_REF='${{ github.ref }}'\n --env GITHUB_ACTIONS\n --env GITHUB_RUN_ID\n --env GITHUB_REPOSITORY\n --env GITHUB_WORKFLOW\n --env GITHUB_RUN_NUMBER\n --env GITHUB_EVENT_NAME\n --env GITHUB_SHA\n --env GITHUB_HEAD_REF\n --env GITHUB_SERVER_URL\n 'ghcr.io/ruby/ruby-ci-image:${{ inputs.tag }}'\n | dataset_sample\yaml\ruby_ruby\.github\actions\compilers\action.yml | action.yml | YAML | 3,739 | 0.95 | 0.02381 | 0.035714 | node-utils | 568 | 2025-04-12T18:35:27.873106 | GPL-3.0 | false | 11b5a47312d1c72b41e43949c74fdb20 |
name: Set up Launchable\ndescription: >-\n Install the required dependencies and execute the necessary Launchable commands for test recording\n\ninputs:\n os:\n required: true\n description: The operating system that CI runs on. This value is used in Launchable flavor.\n\n test-opts:\n default: none\n required: false\n description: >-\n Test options that determine how tests are run.\n This value is used in the Launchable flavor.\n\n launchable-token:\n required: false\n description: >-\n Launchable token is needed if you want to run Launchable on your forked repository.\n See https://github.com/ruby/ruby/wiki/CI-Servers#launchable-ci for details.\n\n builddir:\n required: false\n default: ${{ github.workspace }}\n description: >-\n Directory to create Launchable report file.\n\n srcdir:\n required: false\n default: ${{ github.workspace }}\n description: >-\n Directory to (re-)checkout source codes. Launchable retrieves the commit information\n from the directory.\n\n test-task:\n required: false\n default: ${{ matrix.test_task }}\n description: >-\n Specifies a single test task to be executed.\n This value is used in the Launchable flavor.\n Either 'test-task' or 'multi-test-tasks' must be configured.\n\n test-tasks:\n required: false\n default: '[]'\n description: >-\n Specifies an array of multiple test tasks to be executed.\n For example: '["test", "test-all"]'.\n If you want to run a single test task, use the 'test-task' input instead.\n\n is-yjit:\n required: false\n default: 'false'\n description: >-\n Whether this workflow is executed on YJIT.\n\nruns:\n using: composite\n\n steps:\n - name: Enable Launchable conditionally\n id: enable-launchable\n run: echo "enable-launchable=true" >> $GITHUB_OUTPUT\n shell: bash\n if: >-\n ${{\n (github.repository == 'ruby/ruby'\n || (github.repository != 'ruby/ruby'\n && env.LAUNCHABLE_TOKEN))\n && (inputs.test-task == 'check'\n || inputs.test-task == 'test-all'\n || inputs.test-task == 'test'\n || contains(fromJSON(inputs.test-tasks), 'test-all')\n || contains(fromJSON(inputs.test-tasks), 'test'))\n }}\n\n # Launchable CLI requires Python and Java.\n # https://www.launchableinc.com/docs/resources/cli-reference/\n - name: Set up Python\n uses: actions/setup-python@871daa956ca9ea99f3c3e30acb424b7960676734 # v5.0.0\n with:\n python-version: "3.x"\n if: steps.enable-launchable.outputs.enable-launchable\n\n - name: Set up Java\n uses: actions/setup-java@7a445ee88d4e23b52c33fdc7601e40278616c7f8 # v4.0.0\n with:\n distribution: 'temurin'\n java-version: '17'\n if: steps.enable-launchable.outputs.enable-launchable\n\n - name: Set global vars\n id: global\n shell: bash\n run: |\n test_all_enabled="${{ inputs.test-task == 'check' || inputs.test-task == 'test-all' || contains(fromJSON(inputs.test-tasks), 'test-all') }}"\n btest_enabled="${{ inputs.test-task == 'check' || inputs.test-task == 'test' || contains(fromJSON(inputs.test-tasks), 'test') }}"\n test_spec_enabled="${{ inputs.test-task == 'check' || inputs.test-task == 'test-spec' || contains(fromJSON(inputs.test-tasks), 'test-spec') }}"\n echo test_all_enabled="${test_all_enabled}" >> $GITHUB_OUTPUT\n echo btest_enabled="${btest_enabled}" >> $GITHUB_OUTPUT\n echo test_spec_enabled="${test_spec_enabled}" >> $GITHUB_OUTPUT\n echo test_all_session_file='launchable_test_all_session.txt' >> $GITHUB_OUTPUT\n echo btest_session_file='launchable_btest_session.txt' >> $GITHUB_OUTPUT\n echo test_spec_session_file='launchable_test_spec_session.txt' >> $GITHUB_OUTPUT\n echo test_all_report_file='launchable_test_all_report.json' >> $GITHUB_OUTPUT\n echo btest_report_file='launchable_btest_report.json' >> $GITHUB_OUTPUT\n echo test_spec_report_dir='launchable_test_spec_report' >> $GITHUB_OUTPUT\n if: steps.enable-launchable.outputs.enable-launchable\n\n - name: Set environment variables for Launchable\n shell: bash\n run: |\n : # GITHUB_PULL_REQUEST_URL are used for commenting test reports in Launchable Github App.\n : # https://github.com/launchableinc/cli/blob/v1.80.1/launchable/utils/link.py#L42\n echo "GITHUB_PULL_REQUEST_URL=${{ github.event.pull_request.html_url }}" >> $GITHUB_ENV\n : # The following envs are necessary in Launchable tokenless authentication.\n : # https://github.com/launchableinc/cli/blob/v1.80.1/launchable/utils/authentication.py#L20\n echo "LAUNCHABLE_ORGANIZATION=${{ github.repository_owner }}" >> $GITHUB_ENV\n echo "LAUNCHABLE_WORKSPACE=${{ github.event.repository.name }}" >> $GITHUB_ENV\n : # https://github.com/launchableinc/cli/blob/v1.80.1/launchable/utils/authentication.py#L71\n echo "GITHUB_PR_HEAD_SHA=${{ github.event.pull_request.head.sha || github.sha }}" >> $GITHUB_ENV\n echo "LAUNCHABLE_TOKEN=${{ inputs.launchable-token }}" >> $GITHUB_ENV\n : # To prevent a slowdown in CI, disable request retries when the Launchable server is unstable.\n echo "LAUNCHABLE_SKIP_TIMEOUT_RETRY=1" >> $GITHUB_ENV\n if: steps.enable-launchable.outputs.enable-launchable\n\n - name: Set up path\n shell: bash\n working-directory: ${{ inputs.srcdir }}\n # Since updated PATH variable will be available in only subsequent actions, we need to add the path beforehand.\n # https://docs.github.com/en/actions/using-workflows/workflow-commands-for-github-actions#adding-a-system-path\n run: echo "$(python -msite --user-base)/bin" >> $GITHUB_PATH\n if: steps.enable-launchable.outputs.enable-launchable && startsWith(inputs.os, 'macos')\n\n - name: Set up Launchable\n shell: bash\n working-directory: ${{ inputs.srcdir }}\n run: |\n set -x\n pip install --user launchable\n : # The build name cannot include a slash, so we replace the string here.\n github_ref="${{ github.ref }}"\n github_ref="${github_ref//\//_}"\n : # With the --name option, we need to configure a unique identifier for this build.\n : # To avoid setting the same build name as the CI which runs on other branches, we use the branch name here.\n build_name="${github_ref}_${GITHUB_PR_HEAD_SHA}"\n test_opts="${{ inputs.test-opts }}"\n test_opts="${test_opts// /}"\n test_opts="${test_opts//=/:}"\n test_all_test_suite='test-all'\n btest_test_suite='btest'\n test_spec_test_suite='test-spec'\n if [ "${{ inputs.is-yjit }}" = "true" ]; then\n test_all_test_suite="yjit-${test_all_test_suite}"\n btest_test_suite="yjit-${btest_test_suite}"\n test_spec_test_suite="yjit-${test_spec_test_suite}"\n fi\n launchable record build --name "${build_name}"\n if [ "${test_all_enabled}" = "true" ]; then\n launchable record session \\n --build "${build_name}" \\n --observation \\n --flavor os="${{ inputs.os }}" \\n --flavor test_task="${{ inputs.test-task }}" \\n --flavor test_opts="${test_opts}" \\n --flavor workflow="${{ github.workflow }}" \\n --test-suite ${test_all_test_suite} \\n > "${test_all_session_file}"\n launchable subset \\n --get-tests-from-previous-sessions \\n --non-blocking \\n --target 90% \\n --session "$(cat "${test_all_session_file}")" \\n raw > /dev/null\n echo "TESTS=${TESTS} --launchable-test-reports=${test_all_report_file}" >> $GITHUB_ENV\n fi\n if [ "${btest_enabled}" = "true" ]; then\n launchable record session \\n --build "${build_name}" \\n --observation \\n --flavor os="${{ inputs.os }}" \\n --flavor test_task="${{ inputs.test-task }}" \\n --flavor test_opts="${test_opts}" \\n --flavor workflow="${{ github.workflow }}" \\n --test-suite ${btest_test_suite} \\n > "${btest_session_file}"\n launchable subset \\n --get-tests-from-previous-sessions \\n --non-blocking \\n --target 90% \\n --session "$(cat "${btest_session_file}")" \\n raw > /dev/null\n echo "BTESTS=${BTESTS} --launchable-test-reports=${btest_report_file}" >> $GITHUB_ENV\n fi\n if [ "${test_spec_enabled}" = "true" ]; then\n launchable record session \\n --build "${build_name}" \\n --observation \\n --flavor os="${{ inputs.os }}" \\n --flavor test_task="${{ inputs.test-task }}" \\n --flavor test_opts="${test_opts}" \\n --flavor workflow="${{ github.workflow }}" \\n --test-suite ${test_spec_test_suite} \\n > "${test_spec_session_file}"\n launchable subset \\n --get-tests-from-previous-sessions \\n --non-blocking \\n --target 90% \\n --session "$(cat "${test_spec_session_file}")" \\n raw > /dev/null\n echo "SPECOPTS=${SPECOPTS} --launchable-test-reports=${test_spec_report_dir}" >> $GITHUB_ENV\n fi\n if: steps.enable-launchable.outputs.enable-launchable\n env:\n test_all_enabled: ${{ steps.global.outputs.test_all_enabled }}\n btest_enabled: ${{ steps.global.outputs.btest_enabled }}\n test_spec_enabled: ${{ steps.global.outputs.test_spec_enabled }}\n test_all_session_file: ${{ steps.global.outputs.test_all_session_file }}\n btest_session_file: ${{ steps.global.outputs.btest_session_file }}\n test_spec_session_file: ${{ steps.global.outputs.test_spec_session_file }}\n test_all_report_file: ${{ steps.global.outputs.test_all_report_file }}\n btest_report_file: ${{ steps.global.outputs.btest_report_file }}\n test_spec_report_dir: ${{ steps.global.outputs.test_spec_report_dir }}\n\n - name: Variables to report Launchable\n id: variables\n shell: bash\n working-directory: ${{ inputs.srcdir }}\n run: |\n set -x\n : # report-path from srcdir\n if [ "${srcdir}" = "${{ github.workspace }}" ]; then\n dir=\n else\n # srcdir must be equal to or under workspace\n dir=$(echo ${srcdir:+${srcdir}/} | sed 's:[^/][^/]*/:../:g')\n fi\n if [ "${test_all_enabled}" = "true" ]; then\n test_report_path="${dir}${builddir:+${builddir}/}${test_all_report_file}"\n echo test_report_path="${test_report_path}" >> $GITHUB_OUTPUT\n fi\n if [ "${btest_enabled}" = "true" ]; then\n btest_report_path="${dir}${builddir:+${builddir}/}${btest_report_file}"\n echo btest_report_path="${btest_report_path}" >> $GITHUB_OUTPUT\n fi\n if [ "${test_spec_enabled}" = "true" ]; then\n test_spec_report_path="${dir}${builddir:+${builddir}/}${test_spec_report_dir}"\n mkdir "${test_spec_report_path}"\n echo test_spec_report_path="${test_spec_report_path}" >> $GITHUB_OUTPUT\n fi\n stdout_report_path="${dir}${builddir:+${builddir}/}launchable_stdout.log"\n stderr_report_path="${dir}${builddir:+${builddir}/}launchable_stderr.log"\n echo stdout_report_path="${stdout_report_path}" >> $GITHUB_OUTPUT\n echo stderr_report_path="${stderr_report_path}" >> $GITHUB_OUTPUT\n if: steps.enable-launchable.outputs.enable-launchable\n env:\n srcdir: ${{ inputs.srcdir }}\n builddir: ${{ inputs.builddir }}\n test_all_enabled: ${{ steps.global.outputs.test_all_enabled }}\n btest_enabled: ${{ steps.global.outputs.btest_enabled }}\n test_spec_enabled: ${{ steps.global.outputs.test_spec_enabled }}\n test_all_report_file: ${{ steps.global.outputs.test_all_report_file }}\n btest_report_file: ${{ steps.global.outputs.btest_report_file }}\n test_spec_report_dir: ${{ steps.global.outputs.test_spec_report_dir }}\n\n - name: Record test results in Launchable\n uses: gacts/run-and-post-run@674528335da98a7afc80915ff2b4b860a0b3553a # v1.4.0\n with:\n shell: bash\n working-directory: ${{ inputs.srcdir }}\n post: |\n if [[ "${test_all_enabled}" = "true" ]]; then \\n launchable record attachment \\n --session "$(cat "${test_all_session_file}")" \\n "${stdout_report_path}" \\n "${stderr_report_path}"; \\n launchable record tests \\n --session "$(cat "${test_all_session_file}")" \\n raw "${test_report_path}" || true; \\n fi\n\n if [[ "${btest_enabled}" = "true" ]]; then \\n launchable record attachment \\n --session "$(cat "${btest_session_file}")" \\n "${stdout_report_path}" \\n "${stderr_report_path}"; \\n launchable record tests \\n --session "$(cat "${btest_session_file}")" \\n raw "${btest_report_path}" || true; \\n fi\n\n if [[ "${test_spec_enabled}" = "true" ]]; then \\n launchable record attachment \\n --session "$(cat "${test_spec_session_file}")" \\n "${stdout_report_path}" \\n "${stderr_report_path}"; \\n launchable record tests \\n --session "$(cat "${test_spec_session_file}")" \\n raw ${test_spec_report_path}/* || true; \\n fi\n\n rm -f "${test_all_session_file}"\n rm -f "${btest_session_file}"\n rm -f "${test_spec_session_file}"\n rm -f "${test_report_path}"\n rm -f "${btest_report_path}"\n rm -fr "${test_spec_report_path}"\n rm -f "${stdout_report_path}"\n rm -f "${stderr_report_path}"\n if: ${{ always() && steps.enable-launchable.outputs.enable-launchable }}\n env:\n test_report_path: ${{ steps.variables.outputs.test_report_path }}\n btest_report_path: ${{ steps.variables.outputs.btest_report_path }}\n test_spec_report_path: ${{ steps.variables.outputs.test_spec_report_path }}\n test_all_enabled: ${{ steps.global.outputs.test_all_enabled }}\n btest_enabled: ${{ steps.global.outputs.btest_enabled }}\n test_spec_enabled: ${{ steps.global.outputs.test_spec_enabled }}\n test_all_session_file: ${{ steps.global.outputs.test_all_session_file }}\n btest_session_file: ${{ steps.global.outputs.btest_session_file }}\n test_spec_session_file: ${{ steps.global.outputs.test_spec_session_file }}\n stdout_report_path: ${{ steps.variables.outputs.stdout_report_path }}\n stderr_report_path: ${{ steps.variables.outputs.stderr_report_path }}\n | dataset_sample\yaml\ruby_ruby\.github\actions\launchable\setup\action.yml | action.yml | YAML | 14,807 | 0.95 | 0.083591 | 0.016556 | vue-tools | 73 | 2024-11-29T03:58:43.329305 | Apache-2.0 | false | 20b4869e3f5108ecd0c1dbd1d2d91ef8 |
name: Setup directories etc.\ndescription: >-\n Set up the source code and build directories (plus some\n environmental tweaks)\n\ninputs:\n srcdir:\n required: false\n default: ${{ github.workspace }}\n description: >-\n Directory to (re-)checkout source codes. This will be created\n if absent. If there is no `configure` file that is also\n generated inside.\n\n builddir:\n required: false\n default: ${{ github.workspace }}\n description: >-\n Where binaries and other generated contents go. This will be\n created if absent.\n\n makeup:\n required: false\n type: boolean\n # Note that `default: false` evaluates to a string constant\n # `'false'`, which is a truthy value :sigh:\n # https://github.com/actions/runner/issues/2238\n default: ''\n description: >-\n If set to true, additionally runs `make up`.\n\n checkout:\n required: false\n type: boolean\n default: true\n description: >-\n If set to '' (false), skip running actions/checkout. This is useful when\n you don't want to overwrite a GitHub token that is already set up.\n\n dummy-files:\n required: false\n type: boolean\n default: ''\n description: >-\n If set to true, creates dummy files in build dir.\n\n fetch-depth:\n required: false\n default: '1'\n description: The depth of commit history fetched from the remote repository\n\n clean:\n required: false\n type: boolean\n default: ''\n description: >-\n If set to true, clean build directory.\n\noutputs: {} # nothing?\n\nruns:\n using: composite\n\n steps:\n # Note that `shell: bash` works on both Windows and Linux, but not\n # `shell: sh`. This is because GitHub hosted Windows runners have\n # their bash manually installed.\n - shell: bash\n run: |\n mkdir -p ${{ inputs.srcdir }}\n mkdir -p ${{ inputs.builddir }}\n\n # Did you know that actions/checkout works without git(1)? We are\n # checking that here.\n - id: which\n shell: bash\n run: |\n echo "git=`command -v git`" >> "$GITHUB_OUTPUT"\n echo "sudo=`command -v sudo`" >> "$GITHUB_OUTPUT"\n echo "autoreconf=`command -v autoreconf`" >> "$GITHUB_OUTPUT"\n\n - if: steps.which.outputs.git\n shell: bash\n run: |\n git config --global core.autocrlf false\n git config --global core.eol lf\n git config --global advice.detachedHead 0\n git config --global init.defaultBranch garbage\n\n - if: inputs.checkout\n uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n with:\n path: ${{ inputs.srcdir }}\n fetch-depth: ${{ inputs.fetch-depth }}\n\n - uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # v4.2.3\n with:\n path: ${{ inputs.srcdir }}/.downloaded-cache\n key: downloaded-cache\n\n - if: steps.which.outputs.autoreconf\n shell: bash\n working-directory: ${{ inputs.srcdir }}\n run: ./autogen.sh --install\n\n # This is for MinGW.\n - if: runner.os == 'Windows'\n shell: bash\n run: echo "GNUMAKEFLAGS=-j$((2 * NUMBER_OF_PROCESSORS))" >> $GITHUB_ENV\n\n - if: runner.os == 'Linux'\n shell: bash\n run: echo "GNUMAKEFLAGS=-sj$((1 + $(nproc --all)))" >> "$GITHUB_ENV"\n\n # macOS' GNU make is so old that they doesn't understand `GNUMAKEFLAGS`.\n - if: runner.os == 'macOS'\n shell: bash\n run: echo "MAKEFLAGS=-j$((1 + $(sysctl -n hw.activecpu)))" >> "$GITHUB_ENV"\n\n - if: inputs.makeup\n shell: bash\n working-directory: ${{ inputs.srcdir }}\n run: |\n touch config.status .rbconfig.time\n for mk in Makefile GNUmakefile; do\n sed -f tool/prereq.status template/$mk.in > $mk\n done\n make up\n\n # Cleanup, runs even on failure\n - if: always() && inputs.makeup\n shell: bash\n working-directory: ${{ inputs.srcdir }}\n run: |\n rm -f config.status .rbconfig.time \\n Makefile GNUmakefile uncommon.mk enc.mk noarch-fake.rb\n\n - if: steps.which.outputs.sudo\n shell: bash\n run: |\n sudo chmod -R go-w /usr/share\n chmod -v go-w $HOME $HOME/.config || :\n declare -a dirs # -A is not supported by old bash, e.g. macos\n SAVE_IFS="$IFS" IFS=:; set $PATH\n for d do\n while [ -d "$d" ]; do\n case "$IFS${dirs[*]}$IFS" in *"$IFS$d$IFS"*) ;; *) dirs+=("$d");; esac\n d="${d%/*}"\n done\n done\n IFS="$SAVE_IFS"\n sudo chmod -v go-w "${dirs[@]}" || :\n\n - if: inputs.dummy-files == 'true'\n shell: bash\n id: dummy-files\n working-directory: ${{ inputs.builddir }}\n run: |\n : Create dummy files in build dir\n set {{a..z},{A..Z},{0..9},foo,bar,test,zzz}.rb\n for file; do \\n echo > $file "raise 'do not load $file'"; \\n done\n # drop {a..z}.rb if case-insensitive filesystem\n grep -F A.rb a.rb > /dev/null && set "${@:27}"\n echo clean="cd ${{ inputs.builddir }} && rm $*" >> $GITHUB_OUTPUT\n\n - if: inputs.clean == 'true'\n shell: bash\n id: clean\n run: |\n echo distclean='make -C ${{ inputs.builddir }} distclean' >> $GITHUB_OUTPUT\n echo remained-files='find ${{ inputs.builddir }} -ls' >> $GITHUB_OUTPUT\n [ "${{ inputs.builddir }}" = "${{ inputs.srcdir }}" ] ||\n echo final='rmdir ${{ inputs.builddir }}' >> $GITHUB_OUTPUT\n\n - name: clean\n uses: gacts/run-and-post-run@d803f6920adc9a47eeac4cb6c93dbc2e2890c684 # v1.4.2\n with:\n working-directory:\n post: |\n ${{ steps.dummy-files.outputs.clean }}\n ${{ steps.clean.outputs.distclean }}\n ${{ steps.clean.outputs.remained-files }}\n ${{ steps.clean.outputs.final }}\n | dataset_sample\yaml\ruby_ruby\.github\actions\setup\directories\action.yml | action.yml | YAML | 5,740 | 0.95 | 0.102703 | 0.074534 | python-kit | 271 | 2024-02-26T05:59:53.849309 | MIT | false | 580f5ba7cc353a81e8ffc4e1dbe0c195 |
name: Setup macOS environment\ndescription: >-\n Installs necessary packages via Homebrew.\n\ninputs: {} # nothing?\n\noutputs: {} # nothing?\n\nruns:\n using: composite\n\n steps:\n - name: brew\n shell: bash\n run: |\n brew install --quiet jemalloc gmp libffi openssl@3 zlib autoconf automake libtool\n\n - name: Set ENV\n shell: bash\n run: |\n dir_config() {\n local args=() lib var="$1"; shift\n for lib in "$@"; do\n args+="--with-${lib%@*}-dir=$(brew --prefix $lib)"\n done\n echo "$var=${args[*]}" >> $GITHUB_ENV\n }\n dir_config ruby_configure_args gmp\n dir_config CONFIGURE_ARGS openssl@3\n | dataset_sample\yaml\ruby_ruby\.github\actions\setup\macos\action.yml | action.yml | YAML | 683 | 0.8 | 0.034483 | 0 | python-kit | 141 | 2024-11-13T14:49:14.375022 | Apache-2.0 | false | 7937ca417d7503471127bd642cfc3e7e |
name: Setup ubuntu environment\ndescription: >-\n At the beginning there was no way but to copy & paste `apt-get`\n everywhere. But now that we have composite actions, it seems better\n merge them into one.\n\ninputs:\n arch:\n required: false\n default: ''\n description: >-\n Architecture. Because we run this on a GitHub-hosted runner\n acceptable value for this input is very limited.\n\noutputs:\n arch:\n value: ${{ steps.uname.outputs.uname }}\n description: >-\n Actual architecture. This could be different from the one\n passed to the `inputs.arch`. For instance giving `i386` to this\n action yields `i686`.\n\nruns:\n using: composite\n\n steps:\n - name: set SETARCH\n shell: bash\n run: echo "SETARCH=${setarch}" >> "$GITHUB_ENV"\n env:\n setarch: ${{ inputs.arch && format('setarch {0} --', inputs.arch) }}\n\n - id: uname\n name: uname\n shell: bash\n run: |\n echo uname=`${SETARCH} uname -m` >> "$GITHUB_OUTPUT"\n echo dpkg=`${SETARCH} uname -m | sed s/686/386/` >> "$GITHUB_OUTPUT"\n\n - name: apt-get\n shell: bash\n env:\n arch: ${{ inputs.arch && format(':{0}', steps.uname.outputs.dpkg) || '' }}\n run: |\n set -x\n ${arch:+sudo dpkg --add-architecture ${arch#:}}\n sudo apt-get update -qq || :\n sudo apt-get install --no-install-recommends -qq -y -o=Dpkg::Use-Pty=0 \\n ${arch:+cross}build-essential${arch/:/-} \\n libssl-dev${arch} libyaml-dev${arch} libreadline6-dev${arch} \\n zlib1g-dev${arch} libncurses5-dev${arch} libffi-dev${arch} \\n autoconf ruby\n sudo apt-get install -qq -y pkg-config${arch} || :\n | dataset_sample\yaml\ruby_ruby\.github\actions\setup\ubuntu\action.yml | action.yml | YAML | 1,679 | 0.95 | 0.018868 | 0 | react-lib | 541 | 2023-07-23T03:43:50.767038 | BSD-3-Clause | false | 0786f7d9380bb539d22977fdfe6d95ba |
name: Post a message to slack\ndescription: >-\n We have our ruby/action-slack webhook. However its arguments are\n bit verbose to be listed in every workflow files. Better merge them\n into one.\n\ninputs:\n SLACK_WEBHOOK_URL:\n required: true\n description: >-\n The URL to post the payload. This is an input because it tends\n to be stored in a secrets vault and a composite action cannot\n look into one.\n\n label:\n required: false\n description: >-\n Human-readable description of the run, something like "DEBUG=1".\n This need not be unique among runs.\n\noutputs: {} # Nothing?\n\nruns:\n using: composite\n\n steps:\n - uses: ruby/action-slack@54175162371f1f7c8eb94d7c8644ee2479fcd375 # v3.2.2\n with:\n payload: |\n {\n "ci": "GitHub Actions",\n "env": "${{ github.workflow }}${{ inputs.label && format(' / {0}', inputs.label) }}",\n "url": "https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}",\n "commit": "${{ github.sha }}",\n "branch": "${{ github.ref_name }}"\n }\n env:\n SLACK_WEBHOOK_URL: ${{ inputs.SLACK_WEBHOOK_URL }}\n if: ${{github.event_name == 'push' && startsWith(github.repository, 'ruby/')}}\n | dataset_sample\yaml\ruby_ruby\.github\actions\slack\action.yml | action.yml | YAML | 1,262 | 0.95 | 0.025641 | 0 | node-utils | 403 | 2023-09-23T06:12:16.346912 | BSD-3-Clause | false | e6cae2194e983d076a712688af8dc561 |
name: Annocheck\n\non:\n push:\n paths-ignore:\n - 'doc/**'\n - '**/man/*'\n - '**.md'\n - '**.rdoc'\n - '**/.document'\n - '.*.yml'\n pull_request:\n paths-ignore:\n - 'doc/**'\n - '**/man/*'\n - '**.md'\n - '**.rdoc'\n - '**/.document'\n - '.*.yml'\n merge_group:\n\nconcurrency:\n group: ${{ github.workflow }} / ${{ startsWith(github.event_name, 'pull') && github.ref_name || github.sha }}\n cancel-in-progress: ${{ startsWith(github.event_name, 'pull') }}\n\npermissions:\n contents: read\n\njobs:\n compile:\n name: test-annocheck\n\n runs-on: ubuntu-latest\n\n container:\n image: ghcr.io/ruby/ruby-ci-image:gcc-11\n options: --user root\n\n if: >-\n ${{!(false\n || contains(github.event.head_commit.message, '[DOC]')\n || contains(github.event.head_commit.message, 'Document')\n || contains(github.event.pull_request.title, '[DOC]')\n || contains(github.event.pull_request.title, 'Document')\n || contains(github.event.pull_request.labels.*.name, 'Documentation')\n || (github.event_name == 'push' && github.event.pull_request.user.login == 'dependabot[bot]')\n )}}\n\n env:\n CONFIGURE_TTY: never\n GITPULLOPTIONS: --no-tags origin ${{ github.ref }}\n RUBY_DEBUG: ci rgengc\n RUBY_TESTOPTS: >-\n -q\n --color=always\n --tty=no\n # FIXME: Drop skipping options\n # https://bugs.ruby-lang.org/issues/18061\n # https://sourceware.org/annobin/annobin.html/Test-pie.html\n TEST_ANNOCHECK_OPTS: '--skip-pie --skip-gaps'\n\n steps:\n - run: id\n working-directory:\n\n - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n with:\n sparse-checkout-cone-mode: false\n sparse-checkout: /.github\n\n - uses: ./.github/actions/setup/directories\n with:\n srcdir: src\n builddir: build\n makeup: true\n\n - uses: ruby/setup-ruby@d8d83c3960843afb664e821fed6be52f37da5267 # v1.231.0\n with:\n ruby-version: '3.0'\n bundler: none\n\n # Minimal flags to pass the check.\n # -g0 disables backtraces when SEGV. Do not set that.\n - name: Run configure\n run: >\n ../src/configure -C\n --enable-debug-env\n --disable-install-doc\n --with-ext=-test-/cxxanyargs,+\n --without-valgrind\n --without-jemalloc\n --without-gmp\n --with-gcc="gcc-11 -fcf-protection -Wa,--generate-missing-build-notes=yes"\n --enable-shared\n debugflags=-ggdb3\n optflags=-O2\n LDFLAGS=-Wl,-z,now\n\n - run: make showflags\n\n - run: make\n\n - run: make test-annocheck\n\n - uses: ./.github/actions/slack\n with:\n SLACK_WEBHOOK_URL: ${{ secrets.SIMPLER_ALERTS_URL }} # ruby-lang slack: ruby/simpler-alerts-bot\n if: ${{ failure() }}\n\ndefaults:\n run:\n working-directory: build\n | dataset_sample\yaml\ruby_ruby\.github\workflows\annocheck.yml | annocheck.yml | YAML | 2,949 | 0.8 | 0.017857 | 0.053191 | python-kit | 997 | 2023-07-30T10:00:39.844981 | Apache-2.0 | false | 71cc01bb175bbef08cab42f5ed448e0d |
name: Auto Request Review\non:\n pull_request_target:\n types: [opened, ready_for_review, reopened]\n branches: [master]\n\npermissions:\n contents: read\n\njobs:\n auto-request-review:\n name: Auto Request Review\n runs-on: ubuntu-latest\n if: ${{ github.repository == 'ruby/ruby' && github.base_ref == 'master' }}\n steps:\n - name: Request review based on files changes and/or groups the author belongs to\n uses: necojackarc/auto-request-review@e89da1a8cd7c8c16d9de9c6e763290b6b0e3d424 # v0.13.0\n with:\n # scope: public_repo\n token: ${{ secrets.MATZBOT_GITHUB_TOKEN }}\n | dataset_sample\yaml\ruby_ruby\.github\workflows\auto_request_review.yml | auto_request_review.yml | YAML | 615 | 0.8 | 0.05 | 0.055556 | node-utils | 681 | 2023-08-21T05:27:13.909926 | MIT | false | fa9007d6367b72ea016f4a3f6bc14f65 |
name: BASERUBY Check\n\non:\n push:\n paths-ignore:\n - 'doc/**'\n - '**/man/*'\n - '**.md'\n - '**.rdoc'\n - '**/.document'\n - '.*.yml'\n pull_request:\n paths-ignore:\n - 'doc/**'\n - '**/man/*'\n - '**.md'\n - '**.rdoc'\n - '**/.document'\n - '.*.yml'\n merge_group:\n\nconcurrency:\n group: ${{ github.workflow }} / ${{ startsWith(github.event_name, 'pull') && github.ref_name || github.sha }}\n cancel-in-progress: ${{ startsWith(github.event_name, 'pull') }}\n\npermissions:\n contents: read\n\njobs:\n baseruby:\n name: BASERUBY\n\n runs-on: ubuntu-22.04\n\n if: >-\n ${{!(false\n || contains(github.event.head_commit.message, '[DOC]')\n || contains(github.event.head_commit.message, 'Document')\n || contains(github.event.pull_request.title, '[DOC]')\n || contains(github.event.pull_request.title, 'Document')\n || contains(github.event.pull_request.labels.*.name, 'Documentation')\n || (github.event_name == 'push' && github.event.pull_request.user.login == 'dependabot[bot]')\n )}}\n\n strategy:\n matrix:\n ruby:\n - ruby-3.0\n - ruby-3.1\n - ruby-3.2\n - ruby-3.3\n\n steps:\n - uses: ruby/setup-ruby@d8d83c3960843afb664e821fed6be52f37da5267 # v1.231.0\n with:\n ruby-version: ${{ matrix.ruby }}\n bundler: none\n\n - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n\n - uses: ./.github/actions/setup/ubuntu\n\n - uses: ./.github/actions/setup/directories\n with:\n makeup: true\n\n - run: ./configure --disable-install-doc\n\n - run: make all\n\n - run: make test\n\n - uses: ./.github/actions/slack\n with:\n label: ${{ matrix.ruby }}\n SLACK_WEBHOOK_URL: ${{ secrets.SIMPLER_ALERTS_URL }} # ruby-lang slack: ruby/simpler-alerts-bot\n if: ${{ failure() }}\n | dataset_sample\yaml\ruby_ruby\.github\workflows\baseruby.yml | baseruby.yml | YAML | 1,910 | 0.8 | 0.025974 | 0 | vue-tools | 601 | 2024-07-13T10:33:31.292768 | BSD-3-Clause | false | a4972aa1209c9da13ce760ccb89b561a |
name: bundled_gems\n\non:\n push:\n branches: ['master']\n paths:\n - '.github/workflows/bundled_gems.yml'\n - 'gems/bundled_gems'\n pull_request:\n branches: ['master']\n paths:\n - '.github/workflows/bundled_gems.yml'\n - 'gems/bundled_gems'\n merge_group:\n schedule:\n - cron: '45 6 * * *'\n workflow_dispatch:\n\npermissions: # added using https://github.com/step-security/secure-workflows\n contents: read\n\njobs:\n update:\n permissions:\n contents: write # for Git to git push\n\n if: ${{ github.event_name != 'schedule' || github.repository == 'ruby/ruby' }}\n\n name: update ${{ github.workflow }}\n\n runs-on: ubuntu-latest\n\n steps:\n - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n with:\n token: ${{ (github.repository == 'ruby/ruby' && !startsWith(github.event_name, 'pull')) && secrets.MATZBOT_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}\n\n - uses: ./.github/actions/setup/directories\n with:\n # Skip overwriting MATZBOT_GITHUB_TOKEN\n checkout: '' # false (ref: https://github.com/actions/runner/issues/2238)\n\n - name: Set ENV\n run: |\n echo "TODAY=$(date +%F)" >> $GITHUB_ENV\n\n - name: Download previous gems list\n run: |\n mkdir -p .downloaded-cache\n for data in bundled_gems.json default_gems.json; do\n ln -s .downloaded-cache/$data .\n curl -O -R -z ./$data https://stdgems.org/$data\n done\n\n - name: Update bundled gems list\n id: bundled_gems\n run: |\n ruby -i~ tool/update-bundled_gems.rb gems/bundled_gems >> $GITHUB_OUTPUT\n\n - name: Update spec/bundler/support/builders.rb\n run: |\n #!ruby\n rake_version = File.read("gems/bundled_gems")[/^rake\s+(\S+)/, 1]\n print ARGF.read.sub(/^ *def rake_version\s*\K".*?"/) {rake_version.dump}\n shell: ruby -i~ {0} spec/bundler/support/builders.rb\n\n - name: Maintain updated gems list in NEWS\n run: |\n ruby tool/update-NEWS-gemlist.rb bundled\n\n - name: Check diffs\n id: diff\n run: |\n news= gems=\n git diff --color --no-ext-diff --ignore-submodules --exit-code -- NEWS.md ||\n news=true\n git diff --color --no-ext-diff --ignore-submodules --exit-code -- gems/bundled_gems ||\n gems=true\n git add -- NEWS.md gems/bundled_gems\n git add -- spec/bundler/support/builders.rb\n echo news=$news >> $GITHUB_OUTPUT\n echo gems=$gems >> $GITHUB_OUTPUT\n echo update=${news:-$gems} >> $GITHUB_OUTPUT\n\n - name: Install libraries\n uses: ./.github/actions/setup/ubuntu\n if: ${{ steps.diff.outputs.gems }}\n\n - name: Build\n run: |\n ./autogen.sh\n ./configure -C --disable-install-doc\n make\n if: ${{ steps.diff.outputs.gems }}\n\n - name: Prepare bundled gems\n run: |\n make -s prepare-gems\n if: ${{ steps.diff.outputs.gems }}\n\n - name: Test bundled gems\n run: |\n make -s test-bundled-gems\n timeout-minutes: 30\n env:\n RUBY_TESTOPTS: '-q --tty=no'\n TEST_BUNDLED_GEMS_ALLOW_FAILURES: 'typeprof'\n if: ${{ steps.diff.outputs.gems }}\n\n - name: Commit\n run: |\n git pull --ff-only origin ${GITHUB_REF#refs/heads/}\n message="Update bundled gems list"\n if [ -z "${gems}" ]; then\n git commit --message="${message} at ${GITHUB_SHA:0:30} [ci skip]"\n else\n git commit --message="${message} as of ${TODAY}"\n fi\n git push origin ${GITHUB_REF#refs/heads/}\n env:\n TODAY: ${{ steps.bundled_gems.outputs.latest_date || env.TODAY }}\n EMAIL: svn-admin@ruby-lang.org\n GIT_AUTHOR_NAME: git\n GIT_COMMITTER_NAME: git\n gems: ${{ steps.diff.outputs.gems }}\n if: >-\n ${{\n github.repository == 'ruby/ruby' &&\n !startsWith(github.event_name, 'pull') &&\n steps.diff.outputs.update\n }}\n\n - uses: ./.github/actions/slack\n with:\n SLACK_WEBHOOK_URL: ${{ secrets.SIMPLER_ALERTS_URL }} # ruby-lang slack: ruby/simpler-alerts-bot\n if: ${{ failure() }}\n | dataset_sample\yaml\ruby_ruby\.github\workflows\bundled_gems.yml | bundled_gems.yml | YAML | 4,304 | 0.95 | 0.080882 | 0.017241 | python-kit | 203 | 2025-06-02T05:27:12.592158 | BSD-3-Clause | false | 5d1d63e85701e5645ed54b2b7290d937 |
name: Check Dependencies\non:\n push:\n paths-ignore:\n - 'doc/**'\n - '**/man/*'\n - '**.md'\n - '**.rdoc'\n - '**/.document'\n - '.*.yml'\n pull_request:\n merge_group:\n\nconcurrency:\n group: ${{ github.workflow }} / ${{ startsWith(github.event_name, 'pull') && github.ref_name || github.sha }}\n cancel-in-progress: ${{ startsWith(github.event_name, 'pull') }}\n\npermissions:\n contents: read\n\njobs:\n update-deps:\n name: Dependency checks\n\n strategy:\n matrix:\n os: [ubuntu-latest]\n fail-fast: true\n\n runs-on: ${{ matrix.os }}\n\n steps:\n - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n\n - uses: ./.github/actions/setup/ubuntu\n if: ${{ contains(matrix.os, 'ubuntu') }}\n\n - uses: ./.github/actions/setup/macos\n if: ${{ contains(matrix.os, 'macos') }}\n\n - uses: ./.github/actions/setup/directories\n\n - uses: ruby/setup-ruby@d8d83c3960843afb664e821fed6be52f37da5267 # v1.231.0\n with:\n ruby-version: '3.0'\n bundler: none\n\n - name: Run configure\n run: ./configure -C --disable-install-doc --disable-rubygems --with-gcc 'optflags=-O0' 'debugflags=-save-temps=obj -g'\n\n - run: make all golf\n\n - run: ./goruby -veh\n\n - run: ruby tool/update-deps --fix\n\n - run: git diff --no-ext-diff --ignore-submodules --exit-code\n\n - uses: ./.github/actions/slack\n with:\n label: ${{ matrix.os }} / Dependencies need to update\n SLACK_WEBHOOK_URL: ${{ secrets.SIMPLER_ALERTS_URL }} # ruby-lang slack: ruby/simpler-alerts-bot\n if: ${{ failure() }}\n | dataset_sample\yaml\ruby_ruby\.github\workflows\check_dependencies.yml | check_dependencies.yml | YAML | 1,638 | 0.8 | 0.047619 | 0 | react-lib | 560 | 2025-01-09T21:32:16.824255 | MIT | false | fa34e043fdacccefd65dc53a6a71b7a3 |
name: Misc\non: [push, pull_request, merge_group]\n\nconcurrency:\n group: ${{ github.workflow }} / ${{ startsWith(github.event_name, 'pull') && github.ref_name || github.sha }}\n cancel-in-progress: ${{ startsWith(github.event_name, 'pull') }}\n\npermissions:\n contents: read\n\njobs:\n checks:\n name: Miscellaneous checks\n\n permissions:\n contents: write # for Git to git push\n\n runs-on: ubuntu-latest\n\n steps:\n - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n with:\n token: ${{ (github.repository == 'ruby/ruby' && !startsWith(github.event_name, 'pull')) && secrets.MATZBOT_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}\n\n - uses: ./.github/actions/setup/directories\n with:\n makeup: true\n # Skip overwriting MATZBOT_GITHUB_TOKEN\n checkout: '' # false (ref: https://github.com/actions/runner/issues/2238)\n\n # Run this step first to make sure auto-style commits are pushed\n - name: ${{ github.ref == 'refs/heads/master' && 'Auto-correct' || 'Check for' }} code styles\n run: |\n set -x\n ruby tool/auto-style.rb "$GITHUB_OLD_SHA" "$GITHUB_NEW_SHA" "$PUSH_REF"\n env:\n EMAIL: svn-admin@ruby-lang.org\n GIT_AUTHOR_NAME: git\n GIT_COMMITTER_NAME: git\n GITHUB_OLD_SHA: ${{ startsWith(github.event_name, 'pull') && github.event.pull_request.base.sha || github.event.before }}\n GITHUB_NEW_SHA: ${{ startsWith(github.event_name, 'pull') && github.event.pull_request.merge_commit_sha || github.event.after }}\n PUSH_REF: ${{ github.ref == 'refs/heads/master' && github.ref || '' }}\n if: ${{ github.repository == 'ruby/ruby' }}\n\n - name: Check if C-sources are US-ASCII\n run: |\n grep -r -n --include='*.[chyS]' --include='*.asm' $'[^\t-~]' -- . && exit 1 || :\n\n - name: Check for bash specific substitution in configure.ac\n run: |\n git grep -n '\${[A-Za-z_0-9]*/' -- configure.ac && exit 1 || :\n\n - name: Check for header macros\n run: |\n fail=\n for header in ruby/*.h; do\n git grep -l -F -e $header -e HAVE_`echo $header | tr a-z./ A-Z__` -- . > /dev/null && continue\n fail=1\n echo $header\n done\n exit $fail\n working-directory: include\n\n - name: Generate docs\n id: docs\n run: |\n ruby -W0 --disable-gems -I./lib tool/rdoc-srcdir -q --op html .\n echo htmlout=ruby-html-${GITHUB_SHA:0:10} >> $GITHUB_OUTPUT\n # Generate only when document commit/PR\n if: >-\n ${{false\n || contains(github.event.head_commit.message, '[ruby/rdoc]')\n || contains(github.event.head_commit.message, '[DOC]')\n || contains(github.event.head_commit.message, 'Document')\n || contains(github.event.pull_request.title, '[DOC]')\n || contains(github.event.pull_request.title, 'Document')\n || contains(github.event.pull_request.labels.*.name, 'Documentation')\n }}\n\n - name: Upload docs\n uses: actions/upload-artifact@v4\n with:\n path: html\n name: ${{ steps.docs.outputs.htmlout }}\n if: ${{ steps.docs.outcome == 'success' }}\n\n - uses: ./.github/actions/slack\n with:\n SLACK_WEBHOOK_URL: ${{ secrets.SIMPLER_ALERTS_URL }} # ruby-lang slack: ruby/simpler-alerts-bot\n if: ${{ failure() }}\n | dataset_sample\yaml\ruby_ruby\.github\workflows\check_misc.yml | check_misc.yml | YAML | 3,451 | 0.8 | 0.111111 | 0.039474 | python-kit | 691 | 2025-04-11T17:04:17.412200 | GPL-3.0 | false | 99fc529ac904b8d6bc6963706c34490e |
# Some tests depending on this name 'Compilations' via $GITHUB_WORKFLOW. Make sure to update such tests when renaming this workflow.\nname: Compilations\n\non:\n push:\n paths-ignore:\n - 'doc/**'\n - '**/man/*'\n - '**.md'\n - '**.rdoc'\n - '**/.document'\n - '.*.yml'\n pull_request:\n paths-ignore:\n - 'doc/**'\n - '**/man/*'\n - '**.md'\n - '**.rdoc'\n - '**/.document'\n - '.*.yml'\n merge_group:\n\nconcurrency:\n group: ${{ github.workflow }} / ${{ startsWith(github.event_name, 'pull') && github.ref_name || github.sha }}\n cancel-in-progress: ${{ startsWith(github.event_name, 'pull') }}\n\npermissions:\n contents: read\n\n# Each job is split so that they roughly take 30min to run through.\njobs:\n compile-if:\n name: 'omnibus compilations, trigger'\n runs-on: ubuntu-latest\n if: >-\n ${{!(false\n || contains(github.event.head_commit.message, '[DOC]')\n || contains(github.event.head_commit.message, 'Document')\n || contains(github.event.pull_request.title, '[DOC]')\n || contains(github.event.pull_request.title, 'Document')\n || contains(github.event.pull_request.labels.*.name, 'Documentation')\n || (github.event_name == 'push' && github.event.pull_request.user.login == 'dependabot[bot]')\n )}}\n steps:\n - run: true\n working-directory:\n\n compile1:\n name: 'omnibus compilations, #1'\n runs-on: ubuntu-latest\n needs: compile-if\n if: ${{ needs.compile-if.result == 'success' }}\n timeout-minutes: 60\n services: { docuum: { image: 'stephanmisc/docuum', options: '--init', volumes: [ '/root', '/var/run/docker.sock:/var/run/docker.sock' ] } }\n steps:\n - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n with: { sparse-checkout-cone-mode: false, sparse-checkout: /.github }\n # Set fetch-depth: 10 so that Launchable can receive commits information.\n - { uses: './.github/actions/setup/directories', with: { srcdir: 'src', builddir: 'build', makeup: true, fetch-depth: 10 } }\n - name: 'clang 18 LTO'\n uses: './.github/actions/compilers'\n with:\n tag: clang-18\n with_gcc: 'clang-18 -flto=auto'\n optflags: '-O2'\n enable_shared: false\n - { uses: './.github/actions/compilers', name: '-O0', with: { optflags: '-O0 -march=x86-64 -mtune=generic' } }\n # - { uses: './.github/actions/compilers', name: '-O3', with: { optflags: '-O3 -march=x86-64 -mtune=generic', check: true } }\n\n compile2:\n name: 'omnibus compilations, #2'\n runs-on: ubuntu-latest\n needs: compile-if\n if: ${{ needs.compile-if.result == 'success' }}\n timeout-minutes: 60\n services: { docuum: { image: 'stephanmisc/docuum', options: '--init', volumes: [ '/root', '/var/run/docker.sock:/var/run/docker.sock' ] } }\n steps:\n - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n with: { sparse-checkout-cone-mode: false, sparse-checkout: /.github }\n - { uses: './.github/actions/setup/directories', with: { srcdir: 'src', builddir: 'build', makeup: true, fetch-depth: 10 } }\n - name: 'GCC 13 LTO'\n uses: './.github/actions/compilers'\n with:\n tag: gcc-13\n with_gcc: 'gcc-13 -flto=auto -ffat-lto-objects -Werror=lto-type-mismatch'\n optflags: '-O2'\n enable_shared: false\n - { uses: './.github/actions/compilers', name: 'ext/Setup', with: { static_exts: 'etc json/* */escape' } }\n - { uses: './.github/actions/compilers', name: 'GCC 14', with: { tag: 'gcc-14' } }\n - { uses: './.github/actions/compilers', name: 'GCC 13', with: { tag: 'gcc-13' } }\n - { uses: './.github/actions/compilers', name: 'GCC 12', with: { tag: 'gcc-12' } }\n - { uses: './.github/actions/compilers', name: 'GCC 11', with: { tag: 'gcc-11' } }\n - { uses: './.github/actions/compilers', name: 'GCC 10', with: { tag: 'gcc-10' } }\n - { uses: './.github/actions/compilers', name: 'GCC 9', with: { tag: 'gcc-9' } }\n - { uses: './.github/actions/compilers', name: 'GCC 8', with: { tag: 'gcc-8' } }\n - { uses: './.github/actions/compilers', name: 'GCC 7', with: { tag: 'gcc-7' } }\n\n compile3:\n name: 'omnibus compilations, #3'\n runs-on: ubuntu-latest\n needs: compile-if\n if: ${{ needs.compile-if.result == 'success' }}\n timeout-minutes: 60\n services: { docuum: { image: 'stephanmisc/docuum', options: '--init', volumes: [ '/root', '/var/run/docker.sock:/var/run/docker.sock' ] } }\n steps:\n - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n with: { sparse-checkout-cone-mode: false, sparse-checkout: /.github }\n - { uses: './.github/actions/setup/directories', with: { srcdir: 'src', builddir: 'build', makeup: true, fetch-depth: 10 } }\n - { uses: './.github/actions/compilers', name: 'clang 21', with: { tag: 'clang-21' } }\n - { uses: './.github/actions/compilers', name: 'clang 20', with: { tag: 'clang-20' } }\n - { uses: './.github/actions/compilers', name: 'clang 19', with: { tag: 'clang-19' } }\n - { uses: './.github/actions/compilers', name: 'clang 18', with: { tag: 'clang-18' } }\n - { uses: './.github/actions/compilers', name: 'clang 17', with: { tag: 'clang-17' } }\n - { uses: './.github/actions/compilers', name: 'clang 16', with: { tag: 'clang-16' } }\n - { uses: './.github/actions/compilers', name: 'clang 15', with: { tag: 'clang-15' } }\n - { uses: './.github/actions/compilers', name: 'clang 14', with: { tag: 'clang-14' } }\n\n compile4:\n name: 'omnibus compilations, #4'\n runs-on: ubuntu-latest\n needs: compile-if\n if: ${{ needs.compile-if.result == 'success' }}\n timeout-minutes: 60\n services: { docuum: { image: 'stephanmisc/docuum', options: '--init', volumes: [ '/root', '/var/run/docker.sock:/var/run/docker.sock' ] } }\n steps:\n - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n with: { sparse-checkout-cone-mode: false, sparse-checkout: /.github }\n - { uses: './.github/actions/setup/directories', with: { srcdir: 'src', builddir: 'build', makeup: true, fetch-depth: 10 } }\n - { uses: './.github/actions/compilers', name: 'clang 13', with: { tag: 'clang-13' } }\n - { uses: './.github/actions/compilers', name: 'clang 12', with: { tag: 'clang-12' } }\n - { uses: './.github/actions/compilers', name: 'clang 11', with: { tag: 'clang-11' } }\n - { uses: './.github/actions/compilers', name: 'clang 10', with: { tag: 'clang-10' } }\n # llvm-objcopy<=9 doesn't have --wildcard. It compiles, but leaves Rust symbols in libyjit.o.\n - { uses: './.github/actions/compilers', name: 'clang 9', with: { tag: 'clang-9', append_configure: '--disable-yjit' } }\n - { uses: './.github/actions/compilers', name: 'clang 8', with: { tag: 'clang-8', append_configure: '--disable-yjit' } }\n - { uses: './.github/actions/compilers', name: 'clang 7', with: { tag: 'clang-7', append_configure: '--disable-yjit' } }\n - { uses: './.github/actions/compilers', name: 'clang 6', with: { tag: 'clang-6.0', append_configure: '--disable-yjit' } }\n\n compile5:\n name: 'omnibus compilations, #5'\n runs-on: ubuntu-latest\n needs: compile-if\n if: ${{ needs.compile-if.result == 'success' }}\n timeout-minutes: 60\n services: { docuum: { image: 'stephanmisc/docuum', options: '--init', volumes: [ '/root', '/var/run/docker.sock:/var/run/docker.sock' ] } }\n steps:\n - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n with: { sparse-checkout-cone-mode: false, sparse-checkout: /.github }\n - { uses: './.github/actions/setup/directories', with: { srcdir: 'src', builddir: 'build', makeup: true, fetch-depth: 10 } }\n # -Wno-strict-prototypes is necessary with current clang-15 since\n # older autoconf generate functions without prototype and -pedantic\n # now implies strict-prototypes. Disabling the error but leaving the\n # warning generates a lot of noise from use of ANYARGS in\n # rb_define_method() and friends.\n # See: https://github.com/llvm/llvm-project/commit/11da1b53d8cd3507959022cd790d5a7ad4573d94\n - { uses: './.github/actions/compilers', name: 'C99', with: { CFLAGS: '-std=c99 -Werror=pedantic -pedantic-errors -Wno-strict-prototypes' } }\n - { uses: './.github/actions/compilers', name: 'C11', with: { CFLAGS: '-std=c11 -Werror=pedantic -pedantic-errors -Wno-strict-prototypes' } }\n - { uses: './.github/actions/compilers', name: 'C17', with: { CFLAGS: '-std=c17 -Werror=pedantic -pedantic-errors -Wno-strict-prototypes' } }\n - { uses: './.github/actions/compilers', name: 'C23', with: { CFLAGS: '-std=c2x -Werror=pedantic -pedantic-errors -Wno-strict-prototypes' } }\n - { uses: './.github/actions/compilers', name: 'C++98', with: { CXXFLAGS: '-std=c++98 -Werror=pedantic -pedantic-errors -Wno-c++11-long-long' } }\n - { uses: './.github/actions/compilers', name: 'C++11', with: { CXXFLAGS: '-std=c++11 -Werror=pedantic -pedantic-errors -Wno-c++11-long-long' } }\n - { uses: './.github/actions/compilers', name: 'C++14', with: { CXXFLAGS: '-std=c++14 -Werror=pedantic -pedantic-errors -Wno-c++11-long-long' } }\n - { uses: './.github/actions/compilers', name: 'C++17', with: { CXXFLAGS: '-std=c++17 -Werror=pedantic -pedantic-errors -Wno-c++11-long-long' } }\n\n compile6:\n name: 'omnibus compilations, #6'\n runs-on: ubuntu-latest\n needs: compile-if\n if: ${{ needs.compile-if.result == 'success' }}\n timeout-minutes: 60\n services: { docuum: { image: 'stephanmisc/docuum', options: '--init', volumes: [ '/root', '/var/run/docker.sock:/var/run/docker.sock' ] } }\n steps:\n - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n with: { sparse-checkout-cone-mode: false, sparse-checkout: /.github }\n - { uses: './.github/actions/setup/directories', with: { srcdir: 'src', builddir: 'build', makeup: true, fetch-depth: 10 } }\n - { uses: './.github/actions/compilers', name: 'C++20', with: { CXXFLAGS: '-std=c++20 -Werror=pedantic -pedantic-errors -Wno-c++11-long-long' } }\n - { uses: './.github/actions/compilers', name: 'C++23', with: { CXXFLAGS: '-std=c++23 -Werror=pedantic -pedantic-errors -Wno-c++11-long-long' } }\n - { uses: './.github/actions/compilers', name: 'C++26', with: { CXXFLAGS: '-std=c++26 -Werror=pedantic -pedantic-errors -Wno-c++11-long-long' } }\n - { uses: './.github/actions/compilers', name: 'gmp', with: { append_configure: '--with-gmp', check: 'ruby/test_bignum.rb', mspecopt: "/github/workspace/src/spec/ruby/core/integer" } }\n - { uses: './.github/actions/compilers', name: 'jemalloc', with: { append_configure: '--with-jemalloc' } }\n - { uses: './.github/actions/compilers', name: 'valgrind', with: { append_configure: '--with-valgrind' } }\n - { uses: './.github/actions/compilers', name: 'coroutine=ucontext', with: { append_configure: '--with-coroutine=ucontext' } }\n - { uses: './.github/actions/compilers', name: 'coroutine=pthread', with: { append_configure: '--with-coroutine=pthread' } }\n\n compile7:\n name: 'omnibus compilations, #7'\n runs-on: ubuntu-latest\n needs: compile-if\n if: ${{ needs.compile-if.result == 'success' }}\n timeout-minutes: 60\n services: { docuum: { image: 'stephanmisc/docuum', options: '--init', volumes: [ '/root', '/var/run/docker.sock:/var/run/docker.sock' ] } }\n steps:\n - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n with: { sparse-checkout-cone-mode: false, sparse-checkout: /.github }\n - { uses: './.github/actions/setup/directories', with: { srcdir: 'src', builddir: 'build', makeup: true, fetch-depth: 10 } }\n - { uses: './.github/actions/compilers', name: 'disable-jit', with: { append_configure: '--disable-yjit' } }\n - { uses: './.github/actions/compilers', name: 'disable-dln', with: { append_configure: '--disable-dln' } }\n - { uses: './.github/actions/compilers', name: 'enable-mkmf-verbose', with: { append_configure: '--enable-mkmf-verbose' } }\n - { uses: './.github/actions/compilers', name: 'disable-rubygems', with: { append_configure: '--disable-rubygems' } }\n - { uses: './.github/actions/compilers', name: 'RUBY_DEVEL', with: { append_configure: '--enable-devel' } }\n - { uses: './.github/actions/compilers', name: 'OPT_THREADED_CODE=0', with: { cppflags: '-DOPT_THREADED_CODE=0' } }\n - { uses: './.github/actions/compilers', name: 'OPT_THREADED_CODE=1', with: { cppflags: '-DOPT_THREADED_CODE=1' } }\n - { uses: './.github/actions/compilers', name: 'OPT_THREADED_CODE=2', with: { cppflags: '-DOPT_THREADED_CODE=2' } }\n\n compile8:\n name: 'omnibus compilations, #8'\n runs-on: ubuntu-latest\n needs: compile-if\n if: ${{ needs.compile-if.result == 'success' }}\n timeout-minutes: 60\n services: { docuum: { image: 'stephanmisc/docuum', options: '--init', volumes: [ '/root', '/var/run/docker.sock:/var/run/docker.sock' ] } }\n steps:\n - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n with: { sparse-checkout-cone-mode: false, sparse-checkout: /.github }\n - { uses: './.github/actions/setup/directories', with: { srcdir: 'src', builddir: 'build', makeup: true, fetch-depth: 10 } }\n - { uses: './.github/actions/compilers', name: 'NDEBUG', with: { cppflags: '-DNDEBUG' } }\n - { uses: './.github/actions/compilers', name: 'RUBY_DEBUG', with: { cppflags: '-DRUBY_DEBUG' } }\n - { uses: './.github/actions/compilers', name: 'ARRAY_DEBUG', with: { cppflags: '-DARRAY_DEBUG' } }\n - { uses: './.github/actions/compilers', name: 'BIGNUM_DEBUG', with: { cppflags: '-DBIGNUM_DEBUG' } }\n - { uses: './.github/actions/compilers', name: 'CCAN_LIST_DEBUG', with: { cppflags: '-DCCAN_LIST_DEBUG' } }\n - { uses: './.github/actions/compilers', name: 'CPDEBUG=-1', with: { cppflags: '-DCPDEBUG=-1' } }\n - { uses: './.github/actions/compilers', name: 'ENC_DEBUG', with: { cppflags: '-DENC_DEBUG' } }\n - { uses: './.github/actions/compilers', name: 'GC_DEBUG', with: { cppflags: '-DGC_DEBUG' } }\n\n compile9:\n name: 'omnibus compilations, #9'\n runs-on: ubuntu-latest\n needs: compile-if\n if: ${{ needs.compile-if.result == 'success' }}\n timeout-minutes: 60\n services: { docuum: { image: 'stephanmisc/docuum', options: '--init', volumes: [ '/root', '/var/run/docker.sock:/var/run/docker.sock' ] } }\n steps:\n - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n with: { sparse-checkout-cone-mode: false, sparse-checkout: /.github }\n - { uses: './.github/actions/setup/directories', with: { srcdir: 'src', builddir: 'build', makeup: true, fetch-depth: 10 } }\n - { uses: './.github/actions/compilers', name: 'HASH_DEBUG', with: { cppflags: '-DHASH_DEBUG' } }\n - { uses: './.github/actions/compilers', name: 'ID_TABLE_DEBUG', with: { cppflags: '-DID_TABLE_DEBUG' } }\n - { uses: './.github/actions/compilers', name: 'RGENGC_DEBUG=-1', with: { cppflags: '-DRGENGC_DEBUG=-1' } }\n - { uses: './.github/actions/compilers', name: 'SYMBOL_DEBUG', with: { cppflags: '-DSYMBOL_DEBUG' } }\n - { uses: './.github/actions/compilers', name: 'RGENGC_CHECK_MODE', with: { cppflags: '-DRGENGC_CHECK_MODE' } }\n - { uses: './.github/actions/compilers', name: 'VM_CHECK_MODE', with: { cppflags: '-DVM_CHECK_MODE' } }\n - { uses: './.github/actions/compilers', name: 'USE_EMBED_CI=0', with: { cppflags: '-DUSE_EMBED_CI=0' } }\n - { uses: './.github/actions/compilers', name: 'USE_FLONUM=0', with: { cppflags: '-DUSE_FLONUM=0', append_configure: '--disable-yjit' } }\n\n compileX:\n name: 'omnibus compilations, #10'\n runs-on: ubuntu-latest\n needs: compile-if\n if: ${{ needs.compile-if.result == 'success' }}\n timeout-minutes: 60\n services: { docuum: { image: 'stephanmisc/docuum', options: '--init', volumes: [ '/root', '/var/run/docker.sock:/var/run/docker.sock' ] } }\n steps:\n - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n with: { sparse-checkout-cone-mode: false, sparse-checkout: /.github }\n - { uses: './.github/actions/setup/directories', with: { srcdir: 'src', builddir: 'build', makeup: true, fetch-depth: 10 } }\n - { uses: './.github/actions/compilers', name: 'USE_LAZY_LOAD', with: { cppflags: '-DUSE_LAZY_LOAD' } }\n - { uses: './.github/actions/compilers', name: 'USE_SYMBOL_GC=0', with: { cppflags: '-DUSE_SYMBOL_GC=0' } }\n - { uses: './.github/actions/compilers', name: 'USE_THREAD_CACHE=0', with: { cppflags: '-DUSE_THREAD_CACHE=0' } }\n - { uses: './.github/actions/compilers', name: 'USE_RUBY_DEBUG_LOG=1', with: { cppflags: '-DUSE_RUBY_DEBUG_LOG=1' } }\n - { uses: './.github/actions/compilers', name: 'USE_DEBUG_COUNTER', with: { cppflags: '-DUSE_DEBUG_COUNTER=1' } }\n - { uses: './.github/actions/compilers', name: 'SHARABLE_MIDDLE_SUBSTRING', with: { cppflags: '-DSHARABLE_MIDDLE_SUBSTRING=1' } }\n - { uses: './.github/actions/compilers', name: 'DEBUG_FIND_TIME_NUMGUESS', with: { cppflags: '-DDEBUG_FIND_TIME_NUMGUESS' } }\n - { uses: './.github/actions/compilers', name: 'DEBUG_INTEGER_PACK', with: { cppflags: '-DDEBUG_INTEGER_PACK' } }\n\n compileB:\n name: 'omnibus compilations, #11'\n runs-on: ubuntu-latest\n needs: compile-if\n if: ${{ needs.compile-if.result == 'success' }}\n timeout-minutes: 60\n services: { docuum: { image: 'stephanmisc/docuum', options: '--init', volumes: [ '/root', '/var/run/docker.sock:/var/run/docker.sock' ] } }\n steps:\n - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n with: { sparse-checkout-cone-mode: false, sparse-checkout: /.github }\n - { uses: './.github/actions/setup/directories', with: { srcdir: 'src', builddir: 'build', makeup: true, fetch-depth: 10 } }\n - { uses: './.github/actions/compilers', name: 'GC_DEBUG_STRESS_TO_CLASS', with: { cppflags: '-DGC_DEBUG_STRESS_TO_CLASS' } }\n - { uses: './.github/actions/compilers', name: 'GC_ENABLE_LAZY_SWEEP=0', with: { cppflags: '-DGC_ENABLE_LAZY_SWEEP=0' } }\n - { uses: './.github/actions/compilers', name: 'GC_PROFILE_DETAIL_MEMORY', with: { cppflags: '-DGC_PROFILE_DETAIL_MEMORY' } }\n - { uses: './.github/actions/compilers', name: 'GC_PROFILE_MORE_DETAIL', with: { cppflags: '-DGC_PROFILE_MORE_DETAIL' } }\n - { uses: './.github/actions/compilers', name: 'MALLOC_ALLOCATED_SIZE_CHECK', with: { cppflags: '-DMALLOC_ALLOCATED_SIZE_CHECK' } }\n - { uses: './.github/actions/compilers', name: 'RGENGC_ESTIMATE_OLDMALLOC', with: { cppflags: '-DRGENGC_ESTIMATE_OLDMALLOC' } }\n - { uses: './.github/actions/compilers', name: 'RGENGC_OBJ_INFO', with: { cppflags: '-DRGENGC_OBJ_INFO' } }\n - { uses: './.github/actions/compilers', name: 'RGENGC_PROFILE', with: { cppflags: '-DRGENGC_PROFILE' } }\n\n compileC:\n name: 'omnibus compilations, #12'\n runs-on: ubuntu-latest\n needs: compile-if\n if: ${{ needs.compile-if.result == 'success' }}\n timeout-minutes: 60\n services: { docuum: { image: 'stephanmisc/docuum', options: '--init', volumes: [ '/root', '/var/run/docker.sock:/var/run/docker.sock' ] } }\n steps:\n - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n with: { sparse-checkout-cone-mode: false, sparse-checkout: /.github }\n - { uses: './.github/actions/setup/directories', with: { srcdir: 'src', builddir: 'build', makeup: true, fetch-depth: 10 } }\n - { uses: './.github/actions/compilers', name: 'VM_DEBUG_BP_CHECK', with: { cppflags: '-DVM_DEBUG_BP_CHECK' } }\n - { uses: './.github/actions/compilers', name: 'VM_DEBUG_VERIFY_METHOD_CACHE', with: { cppflags: '-DVM_DEBUG_VERIFY_METHOD_CACHE' } }\n - { uses: './.github/actions/compilers', name: 'enable-yjit', with: { append_configure: '--enable-yjit' } }\n - { uses: './.github/actions/compilers', name: 'YJIT_FORCE_ENABLE', with: { cppflags: '-DYJIT_FORCE_ENABLE' } }\n - { uses: './.github/actions/compilers', name: 'UNIVERSAL_PARSER', with: { cppflags: '-DUNIVERSAL_PARSER' } }\n\n compilemax:\n name: 'omnibus compilations, result'\n runs-on: ubuntu-latest\n if: ${{ always() }}\n needs:\n - 'compile1'\n - 'compile2'\n - 'compile3'\n - 'compile4'\n - 'compile5'\n - 'compile6'\n - 'compile7'\n - 'compile8'\n - 'compile9'\n - 'compileX'\n - 'compileB'\n - 'compileC'\n steps:\n - uses: ./.github/actions/slack\n with:\n label: 'omnibus'\n SLACK_WEBHOOK_URL: ${{ secrets.SIMPLER_ALERTS_URL }} # ruby-lang slack: ruby/simpler-alerts-bot\n if: ${{ contains(needs.*.result, 'failure') || contains(needs.*.result, 'cancelled') }}\n - run: false\n working-directory:\n if: ${{ contains(needs.*.result, 'failure') || contains(needs.*.result, 'cancelled') }}\n\ndefaults:\n run:\n working-directory: build\n | dataset_sample\yaml\ruby_ruby\.github\workflows\compilers.yml | compilers.yml | YAML | 21,686 | 0.95 | 0.123867 | 0.035144 | react-lib | 263 | 2025-05-31T21:56:02.627144 | Apache-2.0 | false | 102e66c7cf6dabf2629a4a6e0969059f |
name: Cygwin\non:\n push:\n paths-ignore:\n - 'doc/**'\n - '**/man/*'\n - '**.md'\n - '**.rdoc'\n - '**/.document'\n - '.*.yml'\n pull_request:\n paths-ignore:\n - 'doc/**'\n - '**/man/*'\n - '**.md'\n - '**.rdoc'\n - '**/.document'\n - '.*.yml'\n merge_group:\n\nconcurrency:\n group: ${{ github.workflow }} / ${{ startsWith(github.event_name, 'pull') && github.ref_name || github.sha }}\n cancel-in-progress: ${{ startsWith(github.event_name, 'pull') }}\n\npermissions:\n contents: read\n\njobs:\n make:\n runs-on: windows-2022\n\n if: >-\n ${{!(false\n || contains(github.event.head_commit.message, '[DOC]')\n || contains(github.event.head_commit.message, 'Document')\n || contains(github.event.pull_request.title, '[DOC]')\n || contains(github.event.pull_request.title, 'Document')\n || contains(github.event.pull_request.labels.*.name, 'Documentation')\n || (github.event_name == 'push' && github.event.pull_request.user.login == 'dependabot[bot]')\n )}}\n\n steps:\n - run: git config --global core.autocrlf input\n\n - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n\n - name: Setup Cygwin\n uses: cygwin/cygwin-install-action@master\n with:\n packages: ruby gcc-core make autoconf libtool libssl-devel libyaml-devel libffi-devel zlib-devel\n\n - name: configure\n run: |\n ./autogen.sh\n ./configure --disable-install-doc\n shell: C:\cygwin\bin\bash.EXE --noprofile --norc -e -o igncr -o pipefail {0}\n\n - name: Extract bundled gems\n run: |\n make ruby -j5\n make extract-gems\n shell: C:\cygwin\bin\bash.EXE --noprofile --norc -e -o igncr -o pipefail {0}\n\n - name: make all\n timeout-minutes: 30\n run: make -j4 V=1\n shell: C:\cygwin\bin\bash.EXE --noprofile --norc -e -o igncr -o pipefail {0}\n | dataset_sample\yaml\ruby_ruby\.github\workflows\cygwin.yml | cygwin.yml | YAML | 1,929 | 0.8 | 0.014925 | 0 | node-utils | 43 | 2024-03-22T18:44:06.379483 | GPL-3.0 | false | a5276c3e67d5cd303380408a19798b54 |
name: Update default gems list\non: [push, pull_request, merge_group]\n\nconcurrency:\n group: ${{ github.workflow }} / ${{ startsWith(github.event_name, 'pull') && github.ref_name || github.sha }}\n cancel-in-progress: ${{ startsWith(github.event_name, 'pull') }}\n\npermissions:\n contents: read\n\njobs:\n update_default_gems:\n name: Update default gems list\n\n permissions:\n contents: write # for Git to git push\n\n runs-on: ubuntu-latest\n\n if: ${{ github.repository == 'ruby/ruby' }}\n\n steps:\n - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n with:\n token: ${{ (github.repository == 'ruby/ruby' && !startsWith(github.event_name, 'pull')) && secrets.MATZBOT_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}\n\n - uses: ./.github/actions/setup/directories\n with:\n makeup: true\n # Skip overwriting MATZBOT_GITHUB_TOKEN\n checkout: '' # false (ref: https://github.com/actions/runner/issues/2238)\n\n - id: gems\n run: true\n if: ${{ github.ref == 'refs/heads/master' }}\n\n - name: Download previous gems list\n run: |\n data=default_gems.json\n mkdir -p .downloaded-cache\n ln -s .downloaded-cache/$data .\n curl -O -R -z ./$data https://stdgems.org/$data\n if: ${{ steps.gems.outcome == 'success' }}\n\n - name: Make default gems list\n run: |\n #!ruby\n require 'rubygems'\n $:.unshift "lib"\n rgver = File.foreach("lib/rubygems.rb") do |line|\n break $1 if /^\s*VERSION\s*=\s*"([^"]+)"/ =~ line\n end\n gems = Dir.glob("{ext,lib}/**/*.gemspec").map do |f|\n spec = Gem::Specification.load(f)\n "#{spec.name} #{spec.version}"\n end.sort\n File.open("gems/default_gems", "w") do |f|\n f.puts "RubyGems #{rgver}"\n f.puts gems\n end\n shell: ruby --disable=gems {0}\n if: ${{ steps.gems.outcome == 'success' }}\n\n - name: Maintain updated gems list in NEWS\n run: |\n ruby tool/update-NEWS-gemlist.rb default\n if: ${{ steps.gems.outcome == 'success' }}\n\n - name: Check diffs\n id: diff\n run: |\n git diff --color --no-ext-diff --ignore-submodules --exit-code NEWS.md ||\n echo update=true >> $GITHUB_OUTPUT\n if: ${{ steps.gems.outcome == 'success' }}\n\n - name: Commit\n run: |\n git pull --ff-only origin ${GITHUB_REF#refs/heads/}\n git commit --message="Update default gems list at ${GITHUB_SHA:0:30} [ci skip]" NEWS.md\n git push origin ${GITHUB_REF#refs/heads/}\n env:\n EMAIL: svn-admin@ruby-lang.org\n GIT_AUTHOR_NAME: git\n GIT_COMMITTER_NAME: git\n if: >-\n ${{\n github.repository == 'ruby/ruby' &&\n !startsWith(github.event_name, 'pull') &&\n steps.diff.outputs.update\n }}\n\n - uses: ./.github/actions/slack\n with:\n SLACK_WEBHOOK_URL: ${{ secrets.SIMPLER_ALERTS_URL }} # ruby-lang slack: ruby/simpler-alerts-bot\n if: ${{ failure() }}\n | dataset_sample\yaml\ruby_ruby\.github\workflows\default_gems.yml | default_gems.yml | YAML | 3,142 | 0.95 | 0.105263 | 0.025 | vue-tools | 185 | 2024-03-13T11:08:27.920142 | Apache-2.0 | false | beef0dc67f4aec14d300e573ae1bfdfe |
# from https://github.com/gofiber/swagger/blob/main/.github/workflows/dependabot_automerge.yml\nname: Dependabot auto-merge\non:\n pull_request:\n\npermissions:\n contents: write\n pull-requests: write\n\njobs:\n automerge:\n runs-on: ubuntu-latest\n if: github.event.pull_request.user.login == 'dependabot[bot]' && github.repository == 'ruby/ruby'\n steps:\n - name: Dependabot metadata\n uses: dependabot/fetch-metadata@d7267f607e9d3fb96fc2fbe83e0af444713e90b7 # v2.3.0\n id: metadata\n\n - name: Wait for status checks\n uses: lewagon/wait-on-check-action@ccfb013c15c8afb7bf2b7c028fb74dc5a068cccc # v1.3.4\n with:\n repo-token: ${{ secrets.MATZBOT_GITHUB_TOKEN }}\n ref: ${{ github.event.pull_request.head.sha || github.sha }}\n check-regexp: 'make \(check, .*\)'\n wait-interval: 30\n\n - name: Auto-merge for Dependabot PRs\n if: ${{ steps.metadata.outputs.update-type == 'version-update:semver-minor' || steps.metadata.outputs.update-type == 'version-update:semver-patch' }}\n run: gh pr merge --auto --rebase "$PR_URL"\n env:\n PR_URL: ${{ github.event.pull_request.html_url }}\n GITHUB_TOKEN: ${{ secrets.MATZBOT_GITHUB_TOKEN }}\n | dataset_sample\yaml\ruby_ruby\.github\workflows\dependabot_automerge.yml | dependabot_automerge.yml | YAML | 1,237 | 0.8 | 0.125 | 0.035714 | awesome-app | 955 | 2024-08-03T07:02:51.798827 | GPL-3.0 | false | 73e8f5c1504445bbab7486f9f4693178 |
name: "Pull Request Labeler"\non:\n- pull_request_target\n\njobs:\n labeler:\n permissions:\n contents: read\n pull-requests: write\n runs-on: ubuntu-latest\n steps:\n - uses: actions/labeler@v5\n | dataset_sample\yaml\ruby_ruby\.github\workflows\labeler.yml | labeler.yml | YAML | 207 | 0.7 | 0 | 0 | vue-tools | 515 | 2023-11-15T08:56:33.922057 | GPL-3.0 | false | 3a4d51c6eef81e5fddf15009bcc5b9cf |
name: MinGW\non:\n push:\n paths-ignore:\n - 'doc/**'\n - '**/man/*'\n - '**.md'\n - '**.rdoc'\n - '**/.document'\n - '.*.yml'\n pull_request:\n paths-ignore:\n - 'doc/**'\n - '**/man/*'\n - '**.md'\n - '**.rdoc'\n - '**/.document'\n - '.*.yml'\n merge_group:\n\nconcurrency:\n group: ${{ github.workflow }} / ${{ startsWith(github.event_name, 'pull') && github.ref_name || github.sha }}\n cancel-in-progress: ${{ startsWith(github.event_name, 'pull') }}\n\npermissions:\n contents: read\n\n# Notes:\n# Actions console encoding causes issues, see test-all & test-spec steps\n#\njobs:\n make:\n runs-on: windows-2022\n\n name: ${{ github.workflow }} (${{ matrix.msystem }})\n\n env:\n MSYSTEM: ${{ matrix.msystem }}\n MSYS2_ARCH: x86_64\n CHOST: 'x86_64-w64-mingw32'\n CFLAGS: '-march=x86-64 -mtune=generic -O3 -pipe'\n CXXFLAGS: '-march=x86-64 -mtune=generic -O3 -pipe'\n CPPFLAGS: '-D_FORTIFY_SOURCE=2 -D__USE_MINGW_ANSI_STDIO=1 -DFD_SETSIZE=2048'\n LDFLAGS: '-pipe'\n GITPULLOPTIONS: --no-tags origin ${{ github.ref }}\n\n strategy:\n matrix:\n include:\n # To mitigate flakiness of MinGW CI, we test only one runtime that newer MSYS2 uses.\n # Ruby 3.2 is the first Windows Ruby to use OpenSSL 3.x\n - msystem: 'UCRT64'\n baseruby: '3.2'\n test_task: 'check'\n test-all-opts: '--name=!/TestObjSpace#test_reachable_objects_during_iteration/'\n fail-fast: false\n\n if: >-\n ${{!(false\n || contains(github.event.head_commit.message, '[DOC]')\n || contains(github.event.head_commit.message, 'Document')\n || contains(github.event.pull_request.title, '[DOC]')\n || contains(github.event.pull_request.title, 'Document')\n || contains(github.event.pull_request.labels.*.name, 'Documentation')\n || (github.event_name == 'push' && github.event.pull_request.user.login == 'dependabot[bot]')\n )}}\n\n steps:\n - name: Set up Ruby & MSYS2\n uses: ruby/setup-ruby@d8d83c3960843afb664e821fed6be52f37da5267 # v1.231.0\n with:\n ruby-version: ${{ matrix.baseruby }}\n\n - name: Misc system & package info\n working-directory:\n run: |\n # show where\n result=true\n for e in gcc.exe ragel.exe make.exe libcrypto-3-x64.dll libssl-3-x64.dll; do\n echo ::group::$'\033[93m'$e$'\033[m'\n where $e || result=false\n echo ::endgroup::\n done\n # show version\n for e in gcc ragel make "openssl version"; do\n case "$e" in *" "*) ;; *) e="$e --version";; esac\n echo ::group::$'\033[93m'$e$'\033[m'\n $e || result=false\n echo ::endgroup::\n done\n # show packages\n echo ::group::$'\033[93m'Packages$'\033[m'\n pacman -Qs mingw-w64-ucrt-x86_64-* | sed -n "s,local/mingw-w64-ucrt-x86_64-,,p"\n echo ::endgroup::\n $result\n\n - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n with:\n sparse-checkout-cone-mode: false\n sparse-checkout: /.github\n\n - uses: ./.github/actions/setup/directories\n with:\n srcdir: src\n builddir: build\n makeup: true\n # Set fetch-depth: 10 so that Launchable can receive commits information.\n fetch-depth: 10\n\n - name: configure\n run: >\n ../src/configure --disable-install-doc --prefix=/.\n --build=$CHOST --host=$CHOST --target=$CHOST\n\n - name: make all\n timeout-minutes: 30\n run: make -j4\n\n - name: make install\n run: make DESTDIR=../install install-nodoc\n\n - name: Set up Launchable\n uses: ./.github/actions/launchable/setup\n with:\n os: windows-2022\n launchable-token: ${{ secrets.LAUNCHABLE_TOKEN }}\n builddir: build\n srcdir: src\n test-tasks: '["test", "test-all", "test-spec"]'\n continue-on-error: true\n\n - name: test\n timeout-minutes: 30\n run: make test\n shell: cmd\n env:\n GNUMAKEFLAGS: ''\n RUBY_TESTOPTS: '-v --tty=no'\n if: ${{ matrix.test_task == 'check' || matrix.test_task == 'test' }}\n\n - name: test-all\n timeout-minutes: 45\n shell: cmd\n run: |\n make ${{ StartsWith(matrix.test_task, 'test/') && matrix.test_task || 'test-all' }}\n env:\n RUBY_TESTOPTS: >-\n --retry --job-status=normal --show-skip --timeout-scale=1.5 -j4\n ${{ matrix.test-all-opts }}\n ${{ env.TESTS }}\n BUNDLER_VERSION:\n if: ${{ matrix.test_task == 'check' || matrix.test_task == 'test-all' || StartsWith(matrix.test_task, 'test/') }}\n\n - name: test-spec\n timeout-minutes: 10\n run: |\n make ${{ StartsWith(matrix.test_task, 'spec/') && matrix.test_task || 'test-spec' }}\n shell: cmd\n if: ${{ matrix.test_task == 'check' || matrix.test_task == 'test-spec' || StartsWith(matrix.test_task, 'spec/') }}\n\n - uses: ./src/.github/actions/slack\n with:\n label: ${{ matrix.msystem }} / ${{ matrix.test_task }}\n SLACK_WEBHOOK_URL: ${{ secrets.SIMPLER_ALERTS_URL }} # ruby-lang slack: ruby/simpler-alerts-bot\n if: ${{ failure() }}\n\ndefaults:\n run:\n working-directory: build\n shell: sh\n | dataset_sample\yaml\ruby_ruby\.github\workflows\mingw.yml | mingw.yml | YAML | 5,427 | 0.8 | 0.041176 | 0.06 | react-lib | 346 | 2023-10-30T19:43:20.391663 | Apache-2.0 | false | dbd35dfd0c9d31497fc7e3573d5ab669 |
name: parse.y\non:\n push:\n paths-ignore:\n - 'doc/**'\n - '**/man/*'\n - '**.md'\n - '**.rdoc'\n - '**/.document'\n - '.*.yml'\n pull_request:\n paths-ignore:\n - 'doc/**'\n - '**/man/*'\n - '**.md'\n - '**.rdoc'\n - '**/.document'\n - '.*.yml'\n merge_group:\n\nconcurrency:\n group: ${{ github.workflow }} / ${{ startsWith(github.event_name, 'pull') && github.ref_name || github.sha }}\n cancel-in-progress: ${{ startsWith(github.event_name, 'pull') }}\n\npermissions:\n contents: read\n\njobs:\n make:\n strategy:\n matrix:\n include:\n - test_task: check\n - test_task: test-bundler-parallel\n - test_task: test-bundled-gems\n fail-fast: false\n\n env:\n GITPULLOPTIONS: --no-tags origin ${{ github.ref }}\n RUBY_DEBUG: ci\n SETARCH: ${{ matrix.arch && format('setarch {0}', matrix.arch) }}\n\n runs-on: ubuntu-22.04\n\n if: >-\n ${{!(false\n || contains(github.event.head_commit.message, '[DOC]')\n || contains(github.event.head_commit.message, 'Document')\n || contains(github.event.pull_request.title, '[DOC]')\n || contains(github.event.pull_request.title, 'Document')\n || contains(github.event.pull_request.labels.*.name, 'Documentation')\n || (github.event_name == 'push' && github.event.pull_request.user.login == 'dependabot[bot]')\n )}}\n\n steps:\n - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n with:\n sparse-checkout-cone-mode: false\n sparse-checkout: /.github\n\n - uses: ./.github/actions/setup/ubuntu\n\n - uses: ./.github/actions/setup/directories\n with:\n srcdir: src\n builddir: build\n makeup: true\n clean: true\n dummy-files: ${{ matrix.test_task == 'check' }}\n\n - name: Run configure\n run: ../src/configure -C --disable-install-doc cppflags=-DRUBY_DEBUG --with-parser=parse.y\n\n - run: make\n\n - run: make TESTRUN_SCRIPT='-e "exit !RUBY_DESCRIPTION.include?(%[+PRISM])"' run\n\n - name: make ${{ matrix.test_task }}\n run: make -s ${{ matrix.test_task }} RUN_OPTS="$RUN_OPTS" SPECOPTS="$SPECOPTS"\n env:\n RUBY_TESTOPTS: ${{ matrix.testopts }}\n EXCLUDES: '../src/test/.excludes-parsey'\n RUN_OPTS: ${{ matrix.run_opts || '--parser=parse.y' }}\n SPECOPTS: ${{ matrix.specopts || '-T --parser=parse.y' }}\n TEST_BUNDLED_GEMS_ALLOW_FAILURES: 'typeprof'\n\n - uses: ./.github/actions/slack\n with:\n label: ${{ matrix.run_opts }}\n SLACK_WEBHOOK_URL: ${{ secrets.SIMPLER_ALERTS_URL }} # ruby-lang slack: ruby/simpler-alerts-bot\n if: ${{ failure() }}\n\ndefaults:\n run:\n working-directory: build\n | dataset_sample\yaml\ruby_ruby\.github\workflows\parsey.yml | parsey.yml | YAML | 2,774 | 0.8 | 0.021053 | 0 | awesome-app | 963 | 2025-03-26T23:38:48.221068 | BSD-3-Clause | false | 71fbd20a141a7f123287d03eeab2e242 |
name: Start release workflow\non:\n push:\n tags:\n - '*'\n\njobs:\n notify:\n runs-on: ubuntu-latest\n steps:\n - name: Build release package\n run: |\n curl -L -X POST \\n -H "Authorization: Bearer ${{ secrets.MATZBOT_GITHUB_WORKFLOW_TOKEN }}" \\n -H "Accept: application/vnd.github+json" \\n -H "X-GitHub-Api-Version: 2022-11-28" \\n https://api.github.com/repos/ruby/actions/dispatches \\n -d '{"event_type": "${{ github.ref }}"}'\n | dataset_sample\yaml\ruby_ruby\.github\workflows\publish.yml | publish.yml | YAML | 510 | 0.8 | 0 | 0 | react-lib | 865 | 2024-06-17T01:36:03.896278 | BSD-3-Clause | false | afca14b7320e3ca8664abfac75d24a3f |
name: Publish Ruby packages\n\non:\n repository_dispatch:\n types:\n - release\n workflow_dispatch:\n inputs:\n version:\n description: 'Version of the Ruby package to release'\n required: true\n default: '3.3.4'\n\njobs:\n release:\n runs-on: ubuntu-latest\n steps:\n - uses: actions/checkout@v4\n\n - uses: ruby/setup-ruby@v1\n with:\n ruby-version: 3.3.4\n\n - name: Store Ruby version\n run: |\n echo "RUBY_VERSION=${{ github.event.client_payload.version || github.event.inputs.version }}" >> $GITHUB_ENV\n\n - name: Store ABI version\n run: echo "ABI_VERSION=$(echo ${{ env.RUBY_VERSION }} | cut -d '.' -f 1-2)" >> $GITHUB_ENV\n\n - name: Copy draft package `/tmp` to `/pub` directory\n run: tool/release.sh ${{ env.RUBY_VERSION }}\n env:\n AWS_ACCESS_KEY_ID: ${{ secrets.FTP_R_L_O_AWS_ACCESS_KEY_ID }}\n AWS_SECRET_ACCESS_KEY: ${{ secrets.FTP_R_L_O_AWS_SECRET_ACCESS_KEY }}\n AWS_DEFAULT_REGION: us-west-2\n\n - name: Purge URLs of release package\n run: |\n curl -X POST \\n -H "Fastly-Key: ${{ secrets.FASTLY_PURGE_TOKEN }}" \\n https://api.fastly.com/purge/cache.ruby-lang.org/pub/ruby/${{ env.ABI_VERSION }}/ruby-${{ env.RUBY_VERSION }}.tar.gz\n curl -X POST \\n -H "Fastly-Key: ${{ secrets.FASTLY_PURGE_TOKEN }}" \\n https://api.fastly.com/purge/cache.ruby-lang.org/pub/ruby/${{ env.ABI_VERSION }}/ruby-${{ env.RUBY_VERSION }}.tar.xz\n curl -X POST \\n -H "Fastly-Key: ${{ secrets.FASTLY_PURGE_TOKEN }}" \\n https://api.fastly.com/purge/cache.ruby-lang.org/pub/ruby/${{ env.ABI_VERSION }}/ruby-${{ env.RUBY_VERSION }}.zip\n\n - name: Create a release on GitHub\n run: |\n RELEASE_TAG=$(echo v${{ env.RUBY_VERSION }} | sed 's/\./_/g')\n echo $RELEASE_TAG\n PREVIOUS_RELEASE_TAG=$(echo $RELEASE_TAG | awk 'BEGIN {FS="_"; OFS="_"}{ $NF=$NF-1; print }')\n echo $PREVIOUS_RELEASE_TAG\n tool/gen-github-release.rb $PREVIOUS_RELEASE_TAG $RELEASE_TAG --no-dry-run\n env:\n GITHUB_TOKEN: ${{ secrets.MATZBOT_GITHUB_WORKFLOW_TOKEN }}\n\n - name: Update versions index\n run: |\n curl -L -X POST \\n -H "Authorization: Bearer ${{ secrets.MATZBOT_GITHUB_WORKFLOW_TOKEN }}" \\n -H "Accept: application/vnd.github+json" \\n -H "X-GitHub-Api-Version: 2022-11-28" \\n https://api.github.com/repos/ruby/actions/dispatches \\n -d '{"event_type": "update_index"}'\n\n - name: Build and push Docker images\n run: |\n curl -L -X POST \\n -H "Authorization: Bearer ${{ secrets.MATZBOT_GITHUB_WORKFLOW_TOKEN }}" \\n -H "Accept: application/vnd.github+json" \\n -H "X-GitHub-Api-Version: 2022-11-28" \\n https://api.github.com/repos/ruby/docker-images/dispatches \\n -d '{"event_type": "build", "client_payload": {"ruby_version": "${{ env.RUBY_VERSION }}"}}'\n\n - name: Build snapcraft packages\n run: |\n curl -L -X POST \\n -H "Authorization: Bearer ${{ secrets.MATZBOT_GITHUB_WORKFLOW_TOKEN }}" \\n -H "Accept: application/vnd.github+json" \\n -H "X-GitHub-Api-Version: 2022-11-28" \\n https://api.github.com/repos/ruby/snap.ruby/dispatches \\n -d '{"event_type": "build", "client_payload": {"ruby_version": "${{ env.RUBY_VERSION }}"}}'\n\n - name: Store the latest LTS version of OpenSSL\n run: |\n echo "OPENSSL_VERSION=`curl -s https://api.github.com/repos/openssl/openssl/releases | jq -r '.[].tag_name | select(startswith("openssl-3.0"))' | sort -Vr | head -n1 | cut -d'-' -f2`" >> $GITHUB_ENV\n\n - name: Update ruby-build definition\n run: |\n curl -L -X POST \\n -H "Authorization: Bearer ${{ secrets.RUBY_BUILD_WORKFLOW_TOKEN }}" \\n -H "Accept: application/vnd.github+json" \\n -H "X-GitHub-Api-Version: 2022-11-28" \\n https://api.github.com/repos/rbenv/ruby-build/dispatches \\n -d '{"event_type": "update-ruby", "client_payload": {"ruby_version": "${{ env.RUBY_VERSION }}", "openssl_version": "${{ env.OPENSSL_VERSION }}"}}'\n\n - name: Update all-ruby definition\n run: |\n curl -L -X POST \\n -H "Authorization: Bearer ${{ secrets.MATZBOT_GITHUB_WORKFLOW_TOKEN }}" \\n -H "Accept: application/vnd.github+json" \\n -H "X-GitHub-Api-Version: 2022-11-28" \\n https://api.github.com/repos/ruby/all-ruby/dispatches \\n -d '{"event_type": "update"}'\n | dataset_sample\yaml\ruby_ruby\.github\workflows\release.yml | release.yml | YAML | 4,674 | 0.95 | 0 | 0 | python-kit | 398 | 2025-07-05T01:12:52.258952 | BSD-3-Clause | false | 37cd49f755613a7ffd0635c7f69d6e9a |
# This workflow uses actions that are not certified by GitHub. They are provided\n# by a third-party and are governed by separate terms of service, privacy\n# policy, and support documentation.\n\nname: Scorecards supply-chain security\non:\n # For Branch-Protection check. Only the default branch is supported. See\n # https://github.com/ossf/scorecard/blob/main/docs/checks.md#branch-protection\n branch_protection_rule:\n # To guarantee Maintained check is occasionally updated. See\n # https://github.com/ossf/scorecard/blob/main/docs/checks.md#maintained\n schedule:\n - cron: '22 4 * * 2'\n # push:\n # branches: [ "master" ]\n\n# Declare default permissions as read only.\npermissions: read-all\n\njobs:\n analysis:\n name: Scorecards analysis\n runs-on: ubuntu-latest\n permissions:\n # Needed to upload the results to code-scanning dashboard.\n security-events: write\n # Needed to publish results and get a badge (see publish_results below).\n id-token: write\n # Uncomment the permissions below if installing in a private repository.\n # contents: read\n # actions: read\n\n steps:\n - name: 'Checkout code'\n uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n with:\n persist-credentials: false\n\n - name: 'Run analysis'\n uses: ossf/scorecard-action@62b2cac7ed8198b15735ed49ab1e5cf35480ba46 # v2.4.0\n with:\n results_file: results.sarif\n results_format: sarif\n # (Optional) Read-only PAT token. Uncomment the `repo_token` line below if:\n # - you want to enable the Branch-Protection check on a *public* repository, or\n # - you are installing Scorecards on a *private* repository\n # To create the PAT, follow the steps in https://github.com/ossf/scorecard-action#authentication-with-pat.\n repo_token: ${{ secrets.SCORECARD_READ_TOKEN }}\n\n # Public repositories:\n # - Publish results to OpenSSF REST API for easy access by consumers\n # - Allows the repository to include the Scorecard badge.\n # - See https://github.com/ossf/scorecard-action#publishing-results.\n # For private repositories:\n # - `publish_results` will always be set to `false`, regardless\n # of the value entered here.\n publish_results: true\n\n # Upload the results as artifacts (optional). Commenting out will disable uploads of run results in SARIF\n # format to the repository Actions tab.\n # - name: "Upload artifact"\n # uses: actions/upload-artifact@0b7f8abb1508181956e8e162db84b466c27e18ce # v3.1.2\n # with:\n # name: SARIF file\n # path: results.sarif\n # retention-days: 5\n\n # Upload the results to GitHub's code scanning dashboard.\n - name: 'Upload to code-scanning'\n uses: github/codeql-action/upload-sarif@df409f7d9260372bd5f19e5b04e83cb3c43714ae # v3.27.9\n with:\n sarif_file: results.sarif\n | dataset_sample\yaml\ruby_ruby\.github\workflows\scorecards.yml | scorecards.yml | YAML | 3,004 | 0.8 | 0.041667 | 0.546875 | node-utils | 662 | 2025-05-28T09:43:54.038453 | GPL-3.0 | false | a0b1b1ebac484e9eee34e6b8099b12a5 |
name: Rubyspec Version Guards Check\n\non:\n push:\n paths:\n - '.github/workflows/spec_guards.yml'\n - 'spec/**'\n - '!spec/*.md'\n pull_request:\n paths:\n - '.github/workflows/spec_guards.yml'\n - 'spec/**'\n - '!spec/*.md'\n merge_group:\n\nconcurrency:\n group: ${{ github.workflow }} / ${{ startsWith(github.event_name, 'pull') && github.ref_name || github.sha }}\n cancel-in-progress: ${{ startsWith(github.event_name, 'pull') }}\n\npermissions:\n contents: read\n\njobs:\n rubyspec:\n name: Rubyspec\n\n runs-on: ubuntu-22.04\n\n if: >-\n ${{!(false\n || contains(github.event.head_commit.message, '[DOC]')\n || contains(github.event.head_commit.message, 'Document')\n || contains(github.event.pull_request.title, '[DOC]')\n || contains(github.event.pull_request.title, 'Document')\n || contains(github.event.pull_request.labels.*.name, 'Documentation')\n || (github.event_name == 'push' && github.event.pull_request.user.login == 'dependabot[bot]')\n )}}\n\n strategy:\n matrix:\n # Specs from ruby/spec should still run on all supported Ruby versions.\n # This also ensures the needed ruby_version_is guards are there, see spec/README.md.\n ruby:\n - ruby-3.1\n - ruby-3.2\n - ruby-3.3\n - ruby-3.4\n\n steps:\n - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n\n - uses: ruby/setup-ruby@d8d83c3960843afb664e821fed6be52f37da5267 # v1.231.0\n with:\n ruby-version: ${{ matrix.ruby }}\n bundler: none\n\n - run: gem install webrick\n\n - run: ruby ../mspec/bin/mspec\n working-directory: spec/ruby\n env:\n CHECK_LEAKS: true\n\n - uses: ./.github/actions/slack\n with:\n label: ${{ matrix.ruby }}\n SLACK_WEBHOOK_URL: ${{ secrets.SIMPLER_ALERTS_URL }} # ruby-lang slack: ruby/simpler-alerts-bot\n if: ${{ failure() }}\n | dataset_sample\yaml\ruby_ruby\.github\workflows\spec_guards.yml | spec_guards.yml | YAML | 1,951 | 0.8 | 0.029412 | 0.035714 | react-lib | 737 | 2023-07-22T23:47:01.733509 | BSD-3-Clause | false | 8e2b3192e451bca2c202b9168677e2ae |
name: Ubuntu\non:\n push:\n paths-ignore:\n - 'doc/**'\n - '**/man/*'\n - '**.md'\n - '**.rdoc'\n - '**/.document'\n - '.*.yml'\n pull_request:\n # Do not use paths-ignore for required status checks\n # https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/collaborating-on-repositories-with-code-quality-features/troubleshooting-required-status-checks#handling-skipped-but-required-checks\n merge_group:\n\nconcurrency:\n group: ${{ github.workflow }} / ${{ startsWith(github.event_name, 'pull') && github.ref_name || github.sha }}\n cancel-in-progress: ${{ startsWith(github.event_name, 'pull') }}\n\npermissions:\n contents: read\n\njobs:\n make:\n strategy:\n matrix:\n include:\n - test_task: check\n configure: 'cppflags=-DVM_CHECK_MODE'\n - test_task: check\n arch: i686\n - test_task: check\n configure: '--disable-yjit'\n - test_task: check\n configure: '--enable-shared --enable-load-relative'\n - test_task: test-bundler-parallel\n timeout: 50\n - test_task: test-bundled-gems\n - test_task: check\n os: ubuntu-24.04\n - test_task: check\n os: ubuntu-24.04-arm\n fail-fast: false\n\n env:\n GITPULLOPTIONS: --no-tags origin ${{ github.ref }}\n RUBY_DEBUG: ci\n\n runs-on: ${{ matrix.os || 'ubuntu-22.04' }}\n\n if: >-\n ${{!(false\n || contains(github.event.head_commit.message, '[DOC]')\n || contains(github.event.head_commit.message, 'Document')\n || contains(github.event.pull_request.title, '[DOC]')\n || contains(github.event.pull_request.title, 'Document')\n || contains(github.event.pull_request.labels.*.name, 'Documentation')\n || (github.event_name == 'push' && github.event.pull_request.user.login == 'dependabot[bot]')\n )}}\n\n steps:\n - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n with:\n sparse-checkout-cone-mode: false\n sparse-checkout: /.github\n\n - uses: ./.github/actions/setup/ubuntu\n with:\n arch: ${{ matrix.arch }}\n\n - uses: ruby/setup-ruby@d8d83c3960843afb664e821fed6be52f37da5267 # v1.231.0\n with:\n ruby-version: '3.0'\n bundler: none\n if: ${{ !endsWith(matrix.os, 'arm') }}\n\n - uses: ./.github/actions/setup/directories\n with:\n srcdir: src\n builddir: build\n makeup: true\n clean: true\n dummy-files: ${{ matrix.test_task == 'check' }}\n # Set fetch-depth: 10 so that Launchable can receive commits information.\n fetch-depth: 10\n\n - name: Run configure\n env:\n arch: ${{ matrix.arch }}\n configure: ${{ matrix.configure }}\n run: >-\n $SETARCH ../src/configure -C --disable-install-doc ${configure:-cppflags=-DRUBY_DEBUG}\n ${arch:+--target=$arch-$OSTYPE --host=$arch-$OSTYPE}\n\n - run: $SETARCH make prepare-gems\n if: ${{ matrix.test_task == 'test-bundled-gems' }}\n\n - run: $SETARCH make\n\n - run: $SETARCH make hello\n\n - name: Set test options for skipped tests\n run: |\n set -x\n TESTS="$(echo "${{ matrix.skipped_tests }}" | sed 's| |$$/ -n!/|g;s|^|-n!/|;s|$|$$/|')"\n echo "TESTS=${TESTS}" >> $GITHUB_ENV\n if: ${{ matrix.test_task == 'check' && matrix.skipped_tests }}\n\n - name: Set up Launchable\n uses: ./.github/actions/launchable/setup\n with:\n os: ${{ matrix.os || 'ubuntu-22.04' }}\n test-opts: ${{ matrix.configure }}\n launchable-token: ${{ secrets.LAUNCHABLE_TOKEN }}\n builddir: build\n srcdir: src\n continue-on-error: true\n\n - name: make ${{ matrix.test_task }}\n run: |\n if [ -n "${LAUNCHABLE_ORGANIZATION}" ]; then\n exec \\n > >(tee launchable_stdout.log) \\n 2> >(tee launchable_stderr.log)\n fi\n\n $SETARCH make -s ${{ matrix.test_task }} \\n ${TESTS:+TESTS="$TESTS"} \\n ${{ !contains(matrix.test_task, 'bundle') && 'RUBYOPT=-w' || '' }}\n timeout-minutes: ${{ matrix.timeout || 40 }}\n env:\n RUBY_TESTOPTS: '-q --tty=no'\n TEST_BUNDLED_GEMS_ALLOW_FAILURES: 'typeprof'\n PRECHECK_BUNDLED_GEMS: 'no'\n\n - name: make skipped tests\n run: |\n $SETARCH make -s test-all TESTS="${TESTS//-n!\//-n/}"\n env:\n GNUMAKEFLAGS: ''\n RUBY_TESTOPTS: '-v --tty=no'\n if: ${{ matrix.test_task == 'check' && matrix.skipped_tests }}\n continue-on-error: ${{ matrix.continue-on-skipped_tests || false }}\n\n - uses: ./.github/actions/slack\n with:\n label: ${{ matrix.test_task }} ${{ matrix.configure }}${{ matrix.arch }}\n SLACK_WEBHOOK_URL: ${{ secrets.SIMPLER_ALERTS_URL }} # ruby-lang slack: ruby/simpler-alerts-bot\n if: ${{ failure() }}\n\n result:\n if: ${{ always() }}\n name: ${{ github.workflow }} result\n runs-on: ubuntu-latest\n needs: [make]\n steps:\n - run: exit 1\n working-directory:\n if: ${{ contains(needs.*.result, 'failure') || contains(needs.*.result, 'cancelled') }}\n\ndefaults:\n run:\n working-directory: build\n | dataset_sample\yaml\ruby_ruby\.github\workflows\ubuntu.yml | ubuntu.yml | YAML | 5,309 | 0.95 | 0.067485 | 0.021277 | awesome-app | 724 | 2024-12-18T14:24:18.379219 | BSD-3-Clause | false | 336d499e9d8ff1b2de5548788636b744 |
name: WebAssembly\non:\n push:\n paths-ignore:\n - 'doc/**'\n - '**/man/*'\n - '**.md'\n - '**.rdoc'\n - '**/.document'\n - '.*.yml'\n pull_request:\n paths-ignore:\n - 'doc/**'\n - '**/man/*'\n - '**.md'\n - '**.rdoc'\n - '**/.document'\n - '.*.yml'\n merge_group:\n\nconcurrency:\n group: ${{ github.workflow }} / ${{ startsWith(github.event_name, 'pull') && github.ref_name || github.sha }}\n cancel-in-progress: ${{ startsWith(github.event_name, 'pull') }}\n\npermissions: # added using https://github.com/step-security/secure-workflows\n contents: read\n\njobs:\n make:\n strategy:\n matrix:\n entry:\n# # wasmtime can't compile non-optimized Asyncified binary due to locals explosion\n# - { name: O0-debuginfo, optflags: '-O0', debugflags: '-g', wasmoptflags: '-O1' }\n# - { name: O1, optflags: '-O1', debugflags: '' , wasmoptflags: '-O1' }\n - { name: O2, optflags: '-O2', debugflags: '', wasmoptflags: '-O2' }\n# - { name: O3, optflags: '-O3', debugflags: '' , wasmoptflags: '-O3' }\n# # -O4 is equivalent to -O3 in clang, but it's different in wasm-opt\n# - { name: O4, optflags: '-O3', debugflags: '' , wasmoptflags: '-O4' }\n# - { name: Oz, optflags: '-Oz', debugflags: '' , wasmoptflags: '-Oz' }\n fail-fast: false\n\n env:\n RUBY_TESTOPTS: '-q --tty=no'\n GITPULLOPTIONS: --no-tags origin ${{ github.ref }}\n WASI_SDK_VERSION_MAJOR: 25\n WASI_SDK_VERSION_MINOR: 0\n BINARYEN_VERSION: 113\n WASMTIME_VERSION: v15.0.0\n\n runs-on: ubuntu-22.04\n\n if: >-\n ${{!(false\n || contains(github.event.head_commit.message, '[DOC]')\n || contains(github.event.head_commit.message, 'Document')\n || contains(github.event.pull_request.title, '[DOC]')\n || contains(github.event.pull_request.title, 'Document')\n || contains(github.event.pull_request.labels.*.name, 'Documentation')\n || (github.event_name == 'push' && github.event.pull_request.user.login == 'dependabot[bot]')\n )}}\n\n steps:\n - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n with:\n sparse-checkout-cone-mode: false\n sparse-checkout: /.github\n\n - uses: ./.github/actions/setup/directories\n with:\n srcdir: src\n builddir: build\n makeup: true\n\n - name: Install libraries\n run: |\n set -ex\n sudo apt-get update -q || :\n sudo apt-get install --no-install-recommends -q -y ruby make autoconf git wget\n\n wasi_sdk_deb="wasi-sdk-${WASI_SDK_VERSION_MAJOR}.${WASI_SDK_VERSION_MINOR}-x86_64-linux.deb"\n wget "https://github.com/WebAssembly/wasi-sdk/releases/download/wasi-sdk-${WASI_SDK_VERSION_MAJOR}/${wasi_sdk_deb}"\n sudo dpkg -i "$wasi_sdk_deb"\n rm -f "$wasi_sdk_deb"\n\n mkdir build-sdk\n pushd build-sdk\n\n wasmtime_url="https://github.com/bytecodealliance/wasmtime/releases/download/${WASMTIME_VERSION}/wasmtime-${WASMTIME_VERSION}-x86_64-linux.tar.xz"\n wget -O - "$wasmtime_url" | tar xJf -\n sudo ln -fs "$PWD/wasmtime-${WASMTIME_VERSION}-x86_64-linux/wasmtime" /usr/local/bin/wasmtime\n\n binaryen_tarball="binaryen-version_${BINARYEN_VERSION}-x86_64-linux.tar.gz"\n binaryen_url="https://github.com/WebAssembly/binaryen/releases/download/version_${BINARYEN_VERSION}/${binaryen_tarball}"\n wget -O - "$binaryen_url" | tar xfz -\n sudo ln -fs "$PWD/binaryen-version_${BINARYEN_VERSION}/bin/wasm-opt" /usr/local/bin/wasm-opt\n working-directory: src\n\n - name: Set ENV\n run: |\n echo "WASI_SDK_PATH=/opt/wasi-sdk" >> $GITHUB_ENV\n\n - uses: ruby/setup-ruby@d8d83c3960843afb664e821fed6be52f37da5267 # v1.231.0\n with:\n ruby-version: '3.0'\n bundler: none\n\n - name: Build baseruby\n run: |\n set -ex\n mkdir ../baseruby\n pushd ../baseruby\n ../src/configure --prefix=$PWD/install\n make\n make install\n\n - name: Download config.guess with wasi version\n run: |\n rm tool/config.guess tool/config.sub\n ruby tool/downloader.rb -d tool -e gnu config.guess config.sub\n working-directory: src\n\n - name: Run configure\n run: |\n ../src/configure \\n --host wasm32-unknown-wasi \\n --with-baseruby=$PWD/../baseruby/install/bin/ruby \\n --with-static-linked-ext \\n --with-ext=cgi/escape,continuation,coverage,date,digest/bubblebabble,digest,digest/md5,digest/rmd160,digest/sha1,digest/sha2,etc,fcntl,json,json/generator,json/parser,objspace,pathname,rbconfig/sizeof,ripper,stringio,strscan,monitor \\n LDFLAGS=" \\n -Xlinker --stack-first \\n -Xlinker -z -Xlinker stack-size=16777216 \\n " \\n optflags="${{ matrix.entry.optflags }}" \\n debugflags="${{ matrix.entry.debugflags }}" \\n wasmoptflags="${{ matrix.entry.wasmoptflags }} ${{ matrix.entry.debugflags }}"\n\n # miniruby may not be built when cross-compling\n - run: make mini ruby\n\n - run: make install DESTDIR=$PWD/../install\n - run: tar cfz ../install.tar.gz -C ../install .\n\n - name: Upload artifacts\n uses: actions/upload-artifact@604373da6381bf24206979c74d06a550515601b9 # v4.4.1\n with:\n name: ruby-wasm-install\n path: ${{ github.workspace }}/install.tar.gz\n - name: Show Playground URL to try the build\n run: |\n echo "Try on Playground: https://ruby.github.io/play-ruby?run=$GITHUB_RUN_ID" >> $GITHUB_STEP_SUMMARY\n\n - name: Run basictest\n run: wasmtime run ./../build/miniruby --mapdir /::./ -- basictest/test.rb\n working-directory: src\n\n - name: Run bootstraptest (no thread)\n run: |\n NO_THREAD_TESTS="$(grep -L Thread -R ./bootstraptest | awk -F/ '{ print $NF }' | uniq | sed -n 's/test_\(.*\).rb/\1/p' | paste -s -d, -)"\n ruby ./bootstraptest/runner.rb --ruby="$(which wasmtime) run $PWD/../build/ruby --mapdir /::./ -- " --verbose "--sets=$NO_THREAD_TESTS"\n working-directory: src\n\n - uses: ./.github/actions/slack\n with:\n label: ${{ matrix.entry.name }}\n SLACK_WEBHOOK_URL: ${{ secrets.SIMPLER_ALERTS_URL }} # ruby-lang slack: ruby/simpler-alerts-bot\n if: ${{ failure() }}\n\n # Workaround for https://github.com/orgs/community/discussions/25220\n - name: Save Pull Request number\n if: ${{ github.event_name == 'pull_request' }}\n run: echo "${{ github.event.pull_request.number }}" >> ${{ github.workspace }}/github-pr-info.txt\n - uses: actions/upload-artifact@604373da6381bf24206979c74d06a550515601b9 # v4.4.1\n if: ${{ github.event_name == 'pull_request' }}\n with:\n name: github-pr-info\n path: ${{ github.workspace }}/github-pr-info.txt\n\ndefaults:\n run:\n working-directory: build\n | dataset_sample\yaml\ruby_ruby\.github\workflows\wasm.yml | wasm.yml | YAML | 7,081 | 0.8 | 0.033149 | 0.058065 | python-kit | 722 | 2023-10-14T02:40:29.348841 | BSD-3-Clause | false | dbe28f05e976e71a2b8a6129137ab1c0 |
name: Windows\non:\n push:\n paths-ignore:\n - 'doc/**'\n - '**/man/*'\n - '**.md'\n - '**.rdoc'\n - '**/.document'\n - '.*.yml'\n pull_request:\n # Do not use paths-ignore for required status checks\n # https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/collaborating-on-repositories-with-code-quality-features/troubleshooting-required-status-checks#handling-skipped-but-required-checks\n merge_group:\n\nconcurrency:\n group: ${{ github.workflow }} / ${{ startsWith(github.event_name, 'pull') && github.ref_name || github.sha }}\n cancel-in-progress: ${{ startsWith(github.event_name, 'pull') }}\n\npermissions:\n contents: read\n\njobs:\n make:\n strategy:\n matrix:\n include:\n - os: 2019\n vc: 2015\n vcvars: '10.0.14393.0 -vcvars_ver=14.0' # The oldest Windows 10 SDK w/ VC++ 2015 toolset (v140)\n test_task: check\n - os: 2019\n vc: 2019\n test_task: check\n - os: 2022\n vc: 2019\n vcvars: '10.0.22621.0 -vcvars_ver=14.2' # The defautl Windows 11 SDK and toolset are broken at windows-2022\n test_task: check\n - os: 2025\n vc: 2019\n vcvars: '10.0.22621.0 -vcvars_ver=14.2'\n test_task: check\n - os: 11-arm\n test_task: 'btest test-basic test-tool' # check and test-spec are broken yet.\n target: arm64\n - os: 2022\n vc: 2019\n vcvars: '10.0.22621.0 -vcvars_ver=14.2'\n test_task: test-bundled-gems\n fail-fast: false\n\n runs-on: windows-${{ matrix.os < 2022 && '2019' || matrix.os }}\n\n if: >-\n ${{!(false\n || contains(github.event.head_commit.message, '[DOC]')\n || contains(github.event.head_commit.message, 'Document')\n || contains(github.event.pull_request.title, '[DOC]')\n || contains(github.event.pull_request.title, 'Document')\n || contains(github.event.pull_request.labels.*.name, 'Documentation')\n || (github.event_name == 'push' && github.event.pull_request.user.login == 'dependabot[bot]')\n )}}\n\n name: Windows ${{ matrix.os }}/Visual C++ ${{ matrix.vc }} (${{ matrix.test_task }})\n\n env:\n GITPULLOPTIONS: --no-tags origin ${{ github.ref }}\n OS_VER: windows-${{ matrix.os < 2022 && '2019' || matrix.os }}\n VCPKG_DEFAULT_TRIPLET: ${{ matrix.target || 'x64' }}-windows\n RUBY_OPT_DIR: ${{ matrix.os == '11-arm' && 'C' || 'D' }}:/a/ruby/ruby/src/vcpkg_installed/%VCPKG_DEFAULT_TRIPLET%\n\n steps:\n - run: md build\n working-directory:\n\n - uses: ruby/setup-ruby@d8d83c3960843afb664e821fed6be52f37da5267 # v1.231.0\n with:\n ruby-version: '3.0'\n bundler: none\n windows-toolchain: none\n if: ${{ matrix.os != '11-arm' }}\n\n - name: Install libraries with scoop\n run: |\n Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser\n iwr -useb get.scoop.sh | iex\n Join-Path (Resolve-Path ~).Path "scoop\shims" >> $Env:GITHUB_PATH\n scoop install vcpkg uutils-coreutils cmake@3.31.6\n shell: pwsh\n\n - name: Export GitHub Actions cache environment variables\n uses: actions/github-script@v7\n with:\n script: |\n core.exportVariable('ACTIONS_CACHE_URL', process.env.ACTIONS_CACHE_URL || '');\n core.exportVariable('ACTIONS_RUNTIME_TOKEN', process.env.ACTIONS_RUNTIME_TOKEN || '');\n\n - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n with:\n sparse-checkout-cone-mode: false\n sparse-checkout: /.github\n\n - uses: ./.github/actions/setup/directories\n with:\n srcdir: src\n builddir: build\n\n - name: setup env\n # Available Ruby versions: https://github.com/actions/runner-images/blob/main/images/windows/Windows2019-Readme.md#ruby\n # %TEMP% is inconsistent with %TMP% and test-all expects they are consistent.\n # https://github.com/actions/virtual-environments/issues/712#issuecomment-613004302\n run: |\n ::- Set up VC ${{ matrix.vc }}\n set vswhere="%ProgramFiles(x86)%\Microsoft Visual Studio\Installer\vswhere.exe"\n for /f "delims=;" %%I in ('%vswhere% -latest -property installationPath') do (\n set VCVARS="%%I\VC\Auxiliary\Build\vcvars64.bat"\n )\n if "${{ matrix.os }}" == "11-arm" (\n set VCVARS="C:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Auxiliary\Build\vcvarsarm64.bat"\n )\n set VCVARS\n set | uutils sort > old.env\n call %VCVARS% ${{ matrix.vcvars || '' }}\n nmake -f nul\n set TMP=%USERPROFILE%\AppData\Local\Temp\n set TEMP=%USERPROFILE%\AppData\Local\Temp\n set MAKEFLAGS=l\n set /a TEST_JOBS=(15 * %NUMBER_OF_PROCESSORS% / 10) > nul\n set | uutils sort > new.env\n uutils comm -13 old.env new.env >> %GITHUB_ENV%\n del *.env\n\n - name: baseruby version\n run: ruby -v\n\n - name: compiler version\n run: cl\n\n - name: volume info\n run: Get-Volume\n shell: pwsh\n\n - name: Install libraries with vcpkg\n run: |\n vcpkg install --vcpkg-root=C:\Users\runneradmin\scoop\apps\vcpkg\current\n working-directory: src\n env:\n VCPKG_BINARY_SOURCES: "clear;x-gha,readwrite"\n\n # TODO: We should use `../src` instead of `D:/a/ruby/ruby/src`\n - name: Configure\n run: >-\n ../src/win32/configure.bat --disable-install-doc\n --with-opt-dir=%RUBY_OPT_DIR%\n --with-gmp\n\n - run: nmake prepare-vcpkg\n\n - run: nmake incs\n\n - run: nmake extract-extlibs\n\n # On all other platforms, test-spec depending on extract-gems (in common.mk) is enough.\n # But not for this Visual Studio workflow. So here we extract gems before building.\n - run: nmake extract-gems\n\n # windows-11-arm runner cannot run `ruby tool/file2lastrev.rb --revision.h --output=revision.h`\n - run: |\n Set-Content -Path "revision.h" -Value @"\n #define RUBY_REVISION "8aedb979da"\n #define RUBY_FULL_REVISION "8aedb979da4090116f4fc5a6497f139fd0038881"\n #define RUBY_BRANCH_NAME "win-arm"\n #define RUBY_RELEASE_DATETIME "2025-04-16T23:18:54Z"\n #define RUBY_RELEASE_YEAR 2025\n #define RUBY_RELEASE_MONTH 4\n #define RUBY_RELEASE_DAY 17\n "@\n shell: pwsh\n if: ${{ matrix.os == '11-arm' }}\n\n - run: nmake\n\n - name: Set up Launchable\n uses: ./.github/actions/launchable/setup\n with:\n os: windows-${{ matrix.os < 2022 && '2019' || matrix.os }}\n launchable-token: ${{ secrets.LAUNCHABLE_TOKEN }}\n builddir: build\n srcdir: src\n test-task: ${{ matrix.test_task || 'check' }}\n continue-on-error: true\n if: ${{ matrix.test_task != 'test-bundled-gems' }}\n\n - run: nmake ${{ matrix.test_task || 'check' }}\n env:\n RUBY_TESTOPTS: -j${{ env.TEST_JOBS || 4 }}\n timeout-minutes: 70\n\n - uses: ./.github/actions/slack\n with:\n label: Windows ${{ matrix.os }} / VC ${{ matrix.vc }} / ${{ matrix.test_task || 'check' }}\n SLACK_WEBHOOK_URL: ${{ secrets.SIMPLER_ALERTS_URL }} # ruby-lang slack: ruby/simpler-alerts-bot\n if: ${{ failure() }}\n\n result:\n if: ${{ always() }}\n name: ${{ github.workflow }} result\n runs-on: windows-latest\n needs: [make]\n steps:\n - run: exit 1\n working-directory:\n if: ${{ contains(needs.*.result, 'failure') || contains(needs.*.result, 'cancelled') }}\n\ndefaults:\n run:\n working-directory: build\n shell: cmd\n | dataset_sample\yaml\ruby_ruby\.github\workflows\windows.yml | windows.yml | YAML | 7,820 | 0.95 | 0.050459 | 0.085106 | react-lib | 974 | 2024-09-23T11:35:19.561368 | MIT | false | 81f4504fb026766fb389bce0f6e662be |
name: Ubuntu on WSL\n\non:\n push:\n paths-ignore:\n - 'doc/**'\n - '**/man/*'\n - '**.md'\n - '**.rdoc'\n - '**/.document'\n - '.*.yml'\n pull_request:\n # Do not use paths-ignore for required status checks\n # https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/collaborating-on-repositories-with-code-quality-features/troubleshooting-required-status-checks#handling-skipped-but-required-checks\n merge_group:\n\njobs:\n wsl:\n runs-on: windows-latest\n\n if: >-\n ${{!(false\n || contains(github.event.head_commit.message, '[DOC]')\n || contains(github.event.head_commit.message, 'Document')\n || contains(github.event.pull_request.title, '[DOC]')\n || contains(github.event.pull_request.title, 'Document')\n || contains(github.event.pull_request.labels.*.name, 'Documentation')\n || (github.event_name == 'push' && github.event.pull_request.user.login == 'dependabot[bot]')\n )}}\n\n steps:\n - name: Install winget\n uses: Cyberboss/install-winget@v1\n\n - name: Install or update WSL\n uses: Ubuntu/WSL/.github/actions/wsl-install@main\n with:\n distro: Ubuntu-24.04\n\n - name: Install dependencies\n uses: Ubuntu/WSL/.github/actions/wsl-bash@main\n with:\n distro: Ubuntu-24.04\n working-dir: /tmp/github/\n exec: |\n DEBIAN_FRONTEND=noninteractive sudo apt update\n DEBIAN_FRONTEND=noninteractive sudo apt install -y ruby build-essential autoconf libssl-dev libyaml-dev zlib1g-dev libgmp-dev libffi-dev\n\n - name: Check out the repository\n uses: Ubuntu/WSL/.github/actions/wsl-checkout@main\n with:\n distro: Ubuntu-24.04\n working-dir: /tmp/github/\n submodules: true\n\n - name: Build\n uses: Ubuntu/WSL/.github/actions/wsl-bash@main\n with:\n distro: Ubuntu-24.04\n working-dir: /tmp/github/\n exec: |\n ./autogen.sh\n ./configure --disable-install-doc\n make ruby -j4\n make extract-gems\n make -j4\n\n - name: Test\n uses: Ubuntu/WSL/.github/actions/wsl-bash@main\n with:\n distro: Ubuntu-24.04\n working-dir: /tmp/github/\n exec: |\n ./ruby -v\n # make check TESTS="-j4" MSPECOPT="-j"\n | dataset_sample\yaml\ruby_ruby\.github\workflows\wsl.yml | wsl.yml | YAML | 2,356 | 0.95 | 0.026667 | 0.045455 | node-utils | 565 | 2024-06-07T12:56:39.615161 | Apache-2.0 | false | a31116c14db4b0034415e740c3e674bd |
name: YJIT macOS Arm64\non:\n push:\n branches:\n - master\n paths-ignore:\n - 'doc/**'\n - '**/man/*'\n - '**.md'\n - '**.rdoc'\n - '**/.document'\n - '.*.yml'\n pull_request:\n types:\n - opened\n - synchronize\n - reopened\n # Do not use paths-ignore for required status checks\n # https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/collaborating-on-repositories-with-code-quality-features/troubleshooting-required-status-checks#handling-skipped-but-required-checks\n merge_group:\n\nconcurrency:\n group: ${{ github.workflow }} / ${{ startsWith(github.event_name, 'pull') && github.ref_name || github.sha }}\n cancel-in-progress: ${{ startsWith(github.event_name, 'pull') }}\n\npermissions:\n contents: read\n\njobs:\n cargo:\n name: cargo test\n\n runs-on: macos-14\n\n if: >-\n ${{!(false\n || contains(github.event.head_commit.message, '[DOC]')\n || contains(github.event.head_commit.message, 'Document')\n || contains(github.event.pull_request.title, '[DOC]')\n || contains(github.event.pull_request.title, 'Document')\n || contains(github.event.pull_request.labels.*.name, 'Documentation')\n || (github.event_name == 'push' && github.event.pull_request.user.login == 'dependabot[bot]')\n )}}\n\n steps:\n - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n\n - run: RUST_BACKTRACE=1 cargo test\n working-directory: yjit\n\n # Also compile and test with all features enabled\n - run: RUST_BACKTRACE=1 cargo test --all-features\n working-directory: yjit\n\n # Check that we can build in release mode too\n - run: cargo build --release\n working-directory: yjit\n\n make:\n strategy:\n matrix:\n include:\n - test_task: 'check'\n configure: '--enable-yjit'\n yjit_opts: '--yjit'\n - test_task: 'check'\n configure: '--enable-yjit=dev'\n yjit_opts: '--yjit-call-threshold=1 --yjit-verify-ctx --yjit-code-gc'\n specopts: '-T --yjit-call-threshold=1 -T --yjit-verify-ctx -T --yjit-code-gc'\n fail-fast: false\n\n env:\n GITPULLOPTIONS: --no-tags origin ${{ github.ref }}\n RUN_OPTS: ${{ matrix.yjit_opts }}\n SPECOPTS: ${{ matrix.specopts }}\n\n runs-on: macos-14\n\n if: >-\n ${{!(false\n || contains(github.event.head_commit.message, '[DOC]')\n || contains(github.event.head_commit.message, 'Document')\n || contains(github.event.pull_request.title, '[DOC]')\n || contains(github.event.pull_request.title, 'Document')\n || contains(github.event.pull_request.labels.*.name, 'Documentation')\n || (github.event_name == 'push' && github.event.pull_request.user.login == 'dependabot[bot]')\n )}}\n\n steps:\n - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n with:\n sparse-checkout-cone-mode: false\n sparse-checkout: /.github\n\n - name: Install libraries\n uses: ./.github/actions/setup/macos\n\n - uses: ./.github/actions/setup/directories\n with:\n srcdir: src\n builddir: build\n makeup: true\n dummy-files: ${{ matrix.test_task == 'check' }}\n # Set fetch-depth: 10 so that Launchable can receive commits information.\n fetch-depth: 10\n\n - name: Run configure\n run: ../src/configure -C --disable-install-doc ${{ matrix.configure }}\n\n - run: make prepare-gems\n if: ${{ matrix.test_task == 'test-bundled-gems' }}\n\n - run: make\n\n - name: Enable YJIT through ENV\n run: echo "RUBY_YJIT_ENABLE=1" >> $GITHUB_ENV\n\n - name: Set test options for skipped tests\n run: |\n set -x\n TESTS="$(echo "${{ matrix.skipped_tests }}" | sed 's| |$$/ -n!/|g;s|^|-n!/|;s|$|$$/|')"\n echo "TESTS=${TESTS}" >> $GITHUB_ENV\n if: ${{ matrix.test_task == 'check' && matrix.skipped_tests }}\n\n - name: Set up Launchable\n uses: ./.github/actions/launchable/setup\n with:\n os: macos-14\n test-opts: ${{ matrix.configure }}\n launchable-token: ${{ secrets.LAUNCHABLE_TOKEN }}\n builddir: build\n srcdir: src\n is-yjit: true\n continue-on-error: true\n\n - name: make ${{ matrix.test_task }}\n run: |\n if [ -n "${LAUNCHABLE_ORGANIZATION}" ]; then\n exec \\n > >(tee launchable_stdout.log) \\n 2> >(tee launchable_stderr.log)\n fi\n\n make -s ${{ matrix.test_task }} ${TESTS:+TESTS="$TESTS"} \\n RUN_OPTS="$RUN_OPTS" \\n SPECOPTS="$SPECOPTS"\n timeout-minutes: 60\n env:\n RUBY_TESTOPTS: '-q --tty=no'\n TEST_BUNDLED_GEMS_ALLOW_FAILURES: 'typeprof'\n SYNTAX_SUGGEST_TIMEOUT: '5'\n PRECHECK_BUNDLED_GEMS: 'no'\n continue-on-error: ${{ matrix.continue-on-test_task || false }}\n\n - name: make skipped tests\n run: |\n make -s test-all TESTS="${TESTS//-n!\//-n/}"\n env:\n GNUMAKEFLAGS: ''\n RUBY_TESTOPTS: '-v --tty=no'\n PRECHECK_BUNDLED_GEMS: 'no'\n if: ${{ matrix.test_task == 'check' && matrix.skipped_tests }}\n continue-on-error: ${{ matrix.continue-on-skipped_tests || false }}\n\n - uses: ./.github/actions/slack\n with:\n label: ${{ matrix.test_task }} ${{ matrix.configure }} ${{ matrix.yjit_opts }}\n SLACK_WEBHOOK_URL: ${{ secrets.SIMPLER_ALERTS_URL }} # ruby-lang slack: ruby/simpler-alerts-bot\n if: ${{ failure() }}\n\n result:\n if: ${{ always() }}\n name: ${{ github.workflow }} result\n runs-on: macos-14\n needs: [make]\n steps:\n - name: ${{ github.workflow }} jobs have failed\n run: exit 1\n working-directory:\n if: ${{ contains(needs.*.result, 'failure') || contains(needs.*.result, 'cancelled') }}\n\ndefaults:\n run:\n working-directory: build\n | dataset_sample\yaml\ruby_ruby\.github\workflows\yjit-macos.yml | yjit-macos.yml | YAML | 5,967 | 0.95 | 0.059783 | 0.032051 | awesome-app | 853 | 2024-06-28T09:35:54.854133 | Apache-2.0 | false | 22740dafc94e2fb586c2ce57804adea5 |
name: YJIT Ubuntu\non:\n push:\n paths-ignore:\n - 'doc/**'\n - '**/man/*'\n - '**.md'\n - '**.rdoc'\n - '**/.document'\n - '.*.yml'\n pull_request:\n # Do not use paths-ignore for required status checks\n # https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/collaborating-on-repositories-with-code-quality-features/troubleshooting-required-status-checks#handling-skipped-but-required-checks\n merge_group:\n\nconcurrency:\n group: ${{ github.workflow }} / ${{ startsWith(github.event_name, 'pull') && github.ref_name || github.sha }}\n cancel-in-progress: ${{ startsWith(github.event_name, 'pull') }}\n\npermissions:\n contents: read\n\njobs:\n cargo:\n name: cargo test\n\n # GitHub Action's image seems to already contain a Rust 1.58.0.\n runs-on: ubuntu-22.04\n\n if: >-\n ${{!(false\n || contains(github.event.head_commit.message, '[DOC]')\n || contains(github.event.pull_request.title, '[DOC]')\n || contains(github.event.pull_request.labels.*.name, 'Documentation')\n || (github.event_name == 'push' && github.event.pull_request.user.login == 'dependabot[bot]')\n )}}\n\n steps:\n - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n\n # For now we can't run cargo test --offline because it complains about the\n # capstone dependency, even though the dependency is optional\n #- run: cargo test --offline\n\n - run: RUST_BACKTRACE=1 cargo test\n working-directory: yjit\n\n # Also compile and test with all features enabled\n - run: RUST_BACKTRACE=1 cargo test --all-features\n working-directory: yjit\n\n # Check that we can build in release mode too\n - run: cargo build --release\n working-directory: yjit\n\n lint:\n name: cargo clippy\n\n # GitHub Action's image seems to already contain a Rust 1.58.0.\n runs-on: ubuntu-22.04\n\n if: >-\n ${{!(false\n || contains(github.event.head_commit.message, '[DOC]')\n || contains(github.event.pull_request.title, '[DOC]')\n || contains(github.event.pull_request.labels.*.name, 'Documentation')\n || (github.event_name == 'push' && github.event.pull_request.user.login == 'dependabot[bot]')\n )}}\n\n steps:\n - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n\n # Check that we don't have linting errors in release mode, too\n - run: cargo clippy --all-targets --all-features\n working-directory: yjit\n\n make:\n strategy:\n fail-fast: false\n matrix:\n include:\n - test_task: 'yjit-bindgen'\n hint: 'To fix: use patch in logs'\n configure: '--with-gcc=clang-14 --enable-yjit=dev'\n libclang_path: '/usr/lib/llvm-14/lib/libclang.so.1'\n\n - test_task: 'check'\n # YJIT should be automatically built in release mode on x86-64 Linux with rustc present\n #configure: "--enable-yjit RUSTC='rustc +1.58.0'"\n configure: "RUSTC='rustc +1.58.0'"\n rust_version: '1.58.0'\n\n - test_task: 'check'\n configure: '--enable-yjit=dev'\n\n - test_task: 'check'\n configure: '--enable-yjit=dev'\n yjit_opts: '--yjit-call-threshold=1 --yjit-verify-ctx --yjit-code-gc'\n specopts: '-T --yjit-call-threshold=1 -T --yjit-verify-ctx -T --yjit-code-gc'\n\n - test_task: 'test-bundled-gems'\n configure: '--enable-yjit=dev'\n\n - test_task: 'yjit-bench'\n configure: '--enable-yjit=dev'\n yjit_bench_opts: '--yjit-stats'\n continue-on-test_task: true\n\n env:\n GITPULLOPTIONS: --no-tags origin ${{ github.ref }}\n RUN_OPTS: ${{ matrix.yjit_opts }}\n YJIT_BENCH_OPTS: ${{ matrix.yjit_bench_opts }}\n SPECOPTS: ${{ matrix.specopts }}\n RUBY_DEBUG: ci\n BUNDLE_JOBS: 8 # for yjit-bench\n RUST_BACKTRACE: 1\n\n runs-on: ubuntu-22.04\n\n if: >-\n ${{!(false\n || contains(github.event.head_commit.message, '[DOC]')\n || contains(github.event.head_commit.message, 'Document')\n || contains(github.event.pull_request.title, '[DOC]')\n || contains(github.event.pull_request.title, 'Document')\n || contains(github.event.pull_request.labels.*.name, 'Documentation')\n || (github.event_name == 'push' && github.event.pull_request.user.login == 'dependabot[bot]')\n )}}\n\n steps:\n - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2\n with:\n sparse-checkout-cone-mode: false\n sparse-checkout: /.github\n\n - uses: ./.github/actions/setup/ubuntu\n\n - uses: ruby/setup-ruby@d8d83c3960843afb664e821fed6be52f37da5267 # v1.231.0\n with:\n ruby-version: '3.0'\n bundler: none\n\n - uses: ./.github/actions/setup/directories\n with:\n srcdir: src\n builddir: build\n makeup: true\n dummy-files: ${{ matrix.test_task == 'check' }}\n # Set fetch-depth: 10 so that Launchable can receive commits information.\n fetch-depth: 10\n\n - name: Install Rust\n if: ${{ matrix.rust_version }}\n run: rustup install ${{ matrix.rust_version }} --profile minimal\n\n - name: Run configure\n run: ../src/configure -C --disable-install-doc --prefix=$(pwd)/install ${{ matrix.configure }}\n\n - run: make incs\n\n - run: make prepare-gems\n if: ${{ matrix.test_task == 'test-bundled-gems' }}\n\n - run: make\n\n - name: Enable YJIT through ENV\n run: echo "RUBY_YJIT_ENABLE=1" >> $GITHUB_ENV\n\n # Check that the binary was built with YJIT\n - name: Check YJIT enabled\n run: ./miniruby --yjit -v | grep "+YJIT"\n\n - name: Set up Launchable\n uses: ./.github/actions/launchable/setup\n with:\n os: ubuntu-22.04\n test-opts: ${{ matrix.configure }}\n launchable-token: ${{ secrets.LAUNCHABLE_TOKEN }}\n builddir: build\n srcdir: src\n is-yjit: true\n continue-on-error: true\n\n - name: make ${{ matrix.test_task }}\n run: |\n if [ -n "${LAUNCHABLE_ORGANIZATION}" ]; then\n exec \\n > >(tee launchable_stdout.log) \\n 2> >(tee launchable_stderr.log)\n fi\n\n make -s ${{ matrix.test_task }} ${TESTS:+TESTS="$TESTS"} \\n RUN_OPTS="$RUN_OPTS" MSPECOPT=--debug SPECOPTS="$SPECOPTS" \\n YJIT_BENCH_OPTS="$YJIT_BENCH_OPTS" YJIT_BINDGEN_DIFF_OPTS="$YJIT_BINDGEN_DIFF_OPTS"\n timeout-minutes: 90\n env:\n RUBY_TESTOPTS: '-q --tty=no'\n TEST_BUNDLED_GEMS_ALLOW_FAILURES: 'typeprof'\n PRECHECK_BUNDLED_GEMS: 'no'\n SYNTAX_SUGGEST_TIMEOUT: '5'\n YJIT_BINDGEN_DIFF_OPTS: '--exit-code'\n LIBCLANG_PATH: ${{ matrix.libclang_path }}\n continue-on-error: ${{ matrix.continue-on-test_task || false }}\n\n - name: Show ${{ github.event.pull_request.base.ref }} GitHub URL for yjit-bench comparison\n run: echo "https://github.com/${BASE_REPO}/commit/${BASE_SHA}"\n env:\n BASE_REPO: ${{ github.event.pull_request.base.repo.full_name }}\n BASE_SHA: ${{ github.event.pull_request.base.sha }}\n if: ${{ matrix.test_task == 'yjit-bench' && startsWith(github.event_name, 'pull') }}\n\n - uses: ./.github/actions/slack\n with:\n label: ${{ matrix.test_task }} ${{ matrix.configure }}\n SLACK_WEBHOOK_URL: ${{ secrets.SIMPLER_ALERTS_URL }} # ruby-lang slack: ruby/simpler-alerts-bot\n if: ${{ failure() }}\n\n result:\n if: ${{ always() }}\n name: ${{ github.workflow }} result\n runs-on: ubuntu-latest\n needs: [make]\n steps:\n - run: exit 1\n working-directory:\n if: ${{ contains(needs.*.result, 'failure') || contains(needs.*.result, 'cancelled') }}\n\ndefaults:\n run:\n working-directory: build\n | dataset_sample\yaml\ruby_ruby\.github\workflows\yjit-ubuntu.yml | yjit-ubuntu.yml | YAML | 7,885 | 0.95 | 0.056522 | 0.074468 | node-utils | 431 | 2023-12-25T18:53:08.108491 | Apache-2.0 | false | a809534017e524516b7a313768ca028e |
name: ZJIT macOS Arm64\non:\n push:\n branches:\n - master\n paths-ignore:\n - 'doc/**'\n - '**/man/*'\n - '**.md'\n - '**.rdoc'\n - '**/.document'\n - '.*.yml'\n pull_request:\n types:\n - opened\n - synchronize\n - reopened\n # Do not use paths-ignore for required status checks\n # https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/collaborating-on-repositories-with-code-quality-features/troubleshooting-required-status-checks#handling-skipped-but-required-checks\n merge_group:\n\nconcurrency:\n group: ${{ github.workflow }} / ${{ startsWith(github.event_name, 'pull') && github.ref_name || github.sha }}\n cancel-in-progress: ${{ startsWith(github.event_name, 'pull') }}\n\npermissions:\n contents: read\n\njobs:\n make:\n strategy:\n fail-fast: false\n matrix:\n include:\n - test_task: 'zjit-test'\n configure: '--enable-zjit=dev'\n\n - test_task: 'test-all'\n configure: '--enable-zjit=dev'\n tests: '../src/test/ruby/test_zjit.rb'\n\n env:\n GITPULLOPTIONS: --no-tags origin ${{ github.ref }}\n RUN_OPTS: ${{ matrix.zjit_opts }}\n SPECOPTS: ${{ matrix.specopts }}\n\n runs-on: macos-14\n\n if: >-\n ${{!(false\n || contains(github.event.head_commit.message, '[DOC]')\n || contains(github.event.head_commit.message, 'Document')\n || contains(github.event.pull_request.title, '[DOC]')\n || contains(github.event.pull_request.title, 'Document')\n || contains(github.event.pull_request.labels.*.name, 'Documentation')\n || (github.event_name == 'push' && github.event.pull_request.user.login == 'dependabot[bot]')\n )}}\n\n steps:\n - uses: actions/checkout@d632683dd7b4114ad314bca15554477dd762a938 # v4.2.0\n with:\n sparse-checkout-cone-mode: false\n sparse-checkout: /.github\n\n - name: Install libraries\n uses: ./.github/actions/setup/macos\n\n - uses: ./.github/actions/setup/directories\n with:\n srcdir: src\n builddir: build\n makeup: true\n dummy-files: ${{ matrix.test_task == 'check' }}\n # Set fetch-depth: 10 so that Launchable can receive commits information.\n fetch-depth: 10\n\n - uses: taiki-e/install-action@v2\n with:\n tool: nextest@0.9\n if: ${{ matrix.test_task == 'zjit-test' }}\n\n - name: Install Rust # TODO(alan): remove when GitHub images catch up past 1.85.0\n run: rustup default 1.85.0\n\n - name: Run configure\n run: ../src/configure -C --disable-install-doc ${{ matrix.configure }}\n\n - run: make prepare-gems\n if: ${{ matrix.test_task == 'test-bundled-gems' }}\n\n - run: make\n\n - name: make ${{ matrix.test_task }}\n run: >-\n make -s ${{ matrix.test_task }} ${TESTS:+TESTS="$TESTS"}\n RUN_OPTS="$RUN_OPTS"\n SPECOPTS="$SPECOPTS"\n timeout-minutes: 60\n env:\n RUBY_TESTOPTS: '-q --tty=no'\n TEST_BUNDLED_GEMS_ALLOW_FAILURES: 'typeprof'\n SYNTAX_SUGGEST_TIMEOUT: '5'\n PRECHECK_BUNDLED_GEMS: 'no'\n TESTS: ${{ matrix.tests }}\n continue-on-error: ${{ matrix.continue-on-test_task || false }}\n\n result:\n if: ${{ always() }}\n name: ${{ github.workflow }} result\n runs-on: macos-14\n needs: [make]\n steps:\n - run: exit 1\n working-directory:\n if: ${{ contains(needs.*.result, 'failure') || contains(needs.*.result, 'cancelled') }}\n\ndefaults:\n run:\n working-directory: build\n | dataset_sample\yaml\ruby_ruby\.github\workflows\zjit-macos.yml | zjit-macos.yml | YAML | 3,570 | 0.95 | 0.058824 | 0.029703 | react-lib | 207 | 2024-11-13T12:37:30.377478 | BSD-3-Clause | false | d61c8b07bd16e8f490a771a054e057e3 |
name: ZJIT Ubuntu\non:\n push:\n branches:\n - master\n paths-ignore:\n - 'doc/**'\n - '**/man/*'\n - '**.md'\n - '**.rdoc'\n - '**/.document'\n - '.*.yml'\n pull_request:\n types:\n - opened\n - synchronize\n - reopened\n # Do not use paths-ignore for required status checks\n # https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/collaborating-on-repositories-with-code-quality-features/troubleshooting-required-status-checks#handling-skipped-but-required-checks\n merge_group:\n\nconcurrency:\n group: ${{ github.workflow }} / ${{ startsWith(github.event_name, 'pull') && github.ref_name || github.sha }}\n cancel-in-progress: ${{ startsWith(github.event_name, 'pull') }}\n\npermissions:\n contents: read\n\njobs:\n make:\n strategy:\n fail-fast: false\n matrix:\n include:\n - test_task: 'zjit-bindgen'\n hint: 'To fix: use patch in logs'\n configure: '--enable-zjit=dev --with-gcc=clang-14'\n libclang_path: '/usr/lib/llvm-14/lib/libclang.so.1'\n\n - test_task: 'zjit-test'\n configure: '--enable-zjit=dev'\n\n - test_task: 'test-all'\n configure: '--enable-zjit=dev'\n tests: '../src/test/ruby/test_zjit.rb'\n\n env:\n GITPULLOPTIONS: --no-tags origin ${{ github.ref }}\n RUN_OPTS: ${{ matrix.zjit_opts }}\n YJIT_BENCH_OPTS: ${{ matrix.yjit_bench_opts }}\n SPECOPTS: ${{ matrix.specopts }}\n RUBY_DEBUG: ci\n BUNDLE_JOBS: 8 # for yjit-bench\n RUST_BACKTRACE: 1\n\n runs-on: ubuntu-22.04\n\n if: >-\n ${{!(false\n || contains(github.event.head_commit.message, '[DOC]')\n || contains(github.event.head_commit.message, 'Document')\n || contains(github.event.pull_request.title, '[DOC]')\n || contains(github.event.pull_request.title, 'Document')\n || contains(github.event.pull_request.labels.*.name, 'Documentation')\n || (github.event_name == 'push' && github.event.pull_request.user.login == 'dependabot[bot]')\n )}}\n\n steps:\n - uses: actions/checkout@d632683dd7b4114ad314bca15554477dd762a938 # v4.2.0\n with:\n sparse-checkout-cone-mode: false\n sparse-checkout: /.github\n\n - uses: ./.github/actions/setup/ubuntu\n\n - uses: ruby/setup-ruby@a6e6f86333f0a2523ece813039b8b4be04560854 # v1.190.0\n with:\n ruby-version: '3.0'\n bundler: none\n\n - uses: taiki-e/install-action@v2\n with:\n tool: nextest@0.9\n if: ${{ matrix.test_task == 'zjit-test' }}\n\n\n - uses: ./.github/actions/setup/directories\n with:\n srcdir: src\n builddir: build\n makeup: true\n dummy-files: ${{ matrix.test_task == 'check' }}\n # Set fetch-depth: 10 so that Launchable can receive commits information.\n fetch-depth: 10\n\n - name: Install Rust\n run: rustup default 1.85.0\n\n - name: Install rustfmt\n if: ${{ matrix.test_task == 'zjit-bindgen' }}\n run: rustup component add rustfmt\n\n - name: Run configure\n run: ../src/configure -C --disable-install-doc --prefix=$(pwd)/install ${{ matrix.configure }}\n\n - run: make incs\n\n - run: make prepare-gems\n if: ${{ matrix.test_task == 'test-bundled-gems' }}\n\n - run: make\n\n # Check that the binary was built with ZJIT\n - name: Check ZJIT enabled\n run: ./miniruby --zjit -v | grep "+ZJIT"\n if: ${{ matrix.configure != '--disable-zjit' }}\n\n - name: make ${{ matrix.test_task }}\n run: >-\n make -s ${{ matrix.test_task }} ${TESTS:+TESTS="$TESTS"}\n RUN_OPTS="$RUN_OPTS" MSPECOPT=--debug SPECOPTS="$SPECOPTS"\n ZJIT_BINDGEN_DIFF_OPTS="$ZJIT_BINDGEN_DIFF_OPTS"\n timeout-minutes: 90\n env:\n RUBY_TESTOPTS: '-q --tty=no'\n TEST_BUNDLED_GEMS_ALLOW_FAILURES: 'typeprof'\n PRECHECK_BUNDLED_GEMS: 'no'\n SYNTAX_SUGGEST_TIMEOUT: '5'\n ZJIT_BINDGEN_DIFF_OPTS: '--exit-code'\n LIBCLANG_PATH: ${{ matrix.libclang_path }}\n TESTS: ${{ matrix.tests }}\n continue-on-error: ${{ matrix.continue-on-test_task || false }}\n\n result:\n if: ${{ always() }}\n name: ${{ github.workflow }} result\n runs-on: ubuntu-22.04\n needs: [make]\n steps:\n - name: ${{ github.workflow }} jobs have failed\n run: exit 1\n working-directory:\n if: ${{ contains(needs.*.result, 'failure') || contains(needs.*.result, 'cancelled') }}\n\ndefaults:\n run:\n working-directory: build\n | dataset_sample\yaml\ruby_ruby\.github\workflows\zjit-ubuntu.yml | zjit-ubuntu.yml | YAML | 4,566 | 0.95 | 0.061224 | 0.03252 | react-lib | 769 | 2024-08-06T18:33:06.946566 | GPL-3.0 | false | 61c7339895641a8438e69dcc89a28b97 |
#\n# Create many HTML strings with ERB.\n#\nprelude: |\n require 'erb'\n\n data = <<erb\n <html>\n <head> <%= title %> </head>\n <body>\n <h1> <%= title %> </h1>\n <p>\n <%= content %>\n </p>\n </body>\n </html>\n erb\n\n title = "hello world!"\n content = "hello world!\n" * 10\nbenchmark:\n app_erb: ERB.new(data).result(binding)\nloop_count: 15000\n | dataset_sample\yaml\ruby_ruby\benchmark\app_erb.yml | app_erb.yml | YAML | 368 | 0.95 | 0 | 0.142857 | python-kit | 735 | 2025-07-06T09:20:15.362129 | BSD-3-Clause | false | 7f37d80bc58e46d8cab256e3266ff4a2 |
prelude: |\n small_flat_ary = 5.times.to_a\n large_flat_ary = 100.times.to_a\n small_pairs_ary = [[1, 2]] * 5\n large_pairs_ary = [[1, 2]] * 100\n mostly_flat_ary = 100.times.to_a.push([101, 102])\n\nbenchmark:\n small_flat_ary.flatten: small_flat_ary.flatten\n small_flat_ary.flatten!: small_flat_ary.flatten!\n large_flat_ary.flatten: large_flat_ary.flatten\n large_flat_ary.flatten!: large_flat_ary.flatten!\n small_pairs_ary.flatten: small_pairs_ary.flatten\n small_pairs_ary.flatten!: small_pairs_ary.dup.flatten!\n large_pairs_ary.flatten: large_pairs_ary.flatten\n large_pairs_ary.flatten!: large_pairs_ary.dup.flatten!\n mostly_flat_ary.flatten: mostly_flat_ary.flatten\n mostly_flat_ary.flatten!: mostly_flat_ary.dup.flatten!\nloop_count: 10000\n | dataset_sample\yaml\ruby_ruby\benchmark\array_flatten.yml | array_flatten.yml | YAML | 751 | 0.7 | 0 | 0 | node-utils | 777 | 2024-09-26T08:16:55.304389 | MIT | false | e1f38ea1513f8c93926044462b68185b |
prelude: |\n small1 = [1, 2, 3]\n small2 = [1, 2, 3, 4, 5]\n small3 = [2, 3, 4, 5]\n small4 = [2]\n big1 = [1, 2, 3, 4] * 64\n big2 = [1, 2, 3] * 64\n big3 = [1, 2] * 64\n\nbenchmark:\n small-&: small1 & small2 & small3 & small4\n small-intersection: small1.intersection(small2, small3, small4)\n big-&: big1 & big2 & big3\n big-intersection: big1.intersection(big2, big3)\n | dataset_sample\yaml\ruby_ruby\benchmark\array_intersection.yml | array_intersection.yml | YAML | 371 | 0.7 | 0 | 0 | react-lib | 900 | 2024-02-16T06:08:14.475953 | GPL-3.0 | false | 7a77dc8750289ca2ffc65fec148c0aab |
prelude: |\n ary2 = 2.times.map(&:to_f).shuffle\n ary10 = 10.times.map(&:to_f).shuffle\n ary100 = 100.times.map(&:to_f).shuffle\n ary500 = 500.times.map(&:to_f).shuffle\n ary1000 = 1000.times.map(&:to_f).shuffle\n ary2000 = 2500.times.map(&:to_f).shuffle\n ary3000 = 2500.times.map(&:to_f).shuffle\n ary5000 = 5000.times.map(&:to_f).shuffle\n ary10000 = 10000.times.map(&:to_f).shuffle\n ary20000 = 20000.times.map(&:to_f).shuffle\n ary50000 = 50000.times.map(&:to_f).shuffle\n ary100000 = 100000.times.map(&:to_f).shuffle\n\nbenchmark:\n ary2.max: ary2.max\n ary10.max: ary10.max\n ary100.max: ary100.max\n ary500.max: ary500.max\n ary1000.max: ary1000.max\n ary2000.max: ary2000.max\n ary3000.max: ary3000.max\n ary5000.max: ary5000.max\n ary10000.max: ary10000.max\n ary20000.max: ary20000.max\n ary50000.max: ary50000.max\n ary100000.max: ary100000.max\n\nloop_count: 10000\n\n | dataset_sample\yaml\ruby_ruby\benchmark\array_max_float.yml | array_max_float.yml | YAML | 875 | 0.7 | 0 | 0 | vue-tools | 882 | 2023-10-23T15:38:24.634623 | MIT | false | b3c3e289551f0517a3422b93dd5e8864 |
prelude: |\n ary2 = 2.times.to_a.shuffle\n ary10 = 10.times.to_a.shuffle\n ary100 = 100.times.to_a.shuffle\n ary500 = 500.times.to_a.shuffle\n ary1000 = 1000.times.to_a.shuffle\n ary2000 = 2500.times.to_a.shuffle\n ary3000 = 2500.times.to_a.shuffle\n ary5000 = 5000.times.to_a.shuffle\n ary10000 = 10000.times.to_a.shuffle\n ary20000 = 20000.times.to_a.shuffle\n ary50000 = 50000.times.to_a.shuffle\n ary100000 = 100000.times.to_a.shuffle\n ary1000000 = 1000000.times.to_a.shuffle\n\nbenchmark:\n ary2.max: ary2.max\n ary10.max: ary10.max\n ary100.max: ary100.max\n ary500.max: ary500.max\n ary1000.max: ary1000.max\n ary2000.max: ary2000.max\n ary3000.max: ary3000.max\n ary5000.max: ary5000.max\n ary10000.max: ary10000.max\n ary20000.max: ary20000.max\n ary50000.max: ary50000.max\n ary100000.max: ary100000.max\n ary1000000.max: ary1000000.max\n\nloop_count: 10000\n | dataset_sample\yaml\ruby_ruby\benchmark\array_max_int.yml | array_max_int.yml | YAML | 865 | 0.7 | 0 | 0 | vue-tools | 506 | 2025-02-11T16:31:18.490419 | Apache-2.0 | false | 652aceb99e9ec76a77819c52f7cedbef |
prelude: |\n ary2 = 2.times.map(&:to_s).shuffle\n ary10 = 10.times.map(&:to_s).shuffle\n ary100 = 100.times.map(&:to_s).shuffle\n ary500 = 500.times.map(&:to_s).shuffle\n ary1000 = 1000.times.map(&:to_s).shuffle\n ary2000 = 2500.times.map(&:to_s).shuffle\n ary3000 = 2500.times.map(&:to_s).shuffle\n ary5000 = 5000.times.map(&:to_s).shuffle\n ary10000 = 10000.times.map(&:to_s).shuffle\n ary20000 = 20000.times.map(&:to_s).shuffle\n ary50000 = 50000.times.map(&:to_s).shuffle\n ary100000 = 100000.times.map(&:to_s).shuffle\n\nbenchmark:\n ary2.max: ary2.max\n ary10.max: ary10.max\n ary100.max: ary100.max\n ary500.max: ary500.max\n ary1000.max: ary1000.max\n ary2000.max: ary2000.max\n ary3000.max: ary3000.max\n ary5000.max: ary5000.max\n ary10000.max: ary10000.max\n ary20000.max: ary20000.max\n ary50000.max: ary50000.max\n ary100000.max: ary100000.max\n\nloop_count: 10000\n\n | dataset_sample\yaml\ruby_ruby\benchmark\array_max_str.yml | array_max_str.yml | YAML | 875 | 0.7 | 0 | 0 | python-kit | 295 | 2023-11-30T23:51:16.482016 | GPL-3.0 | false | a08a543e352aa7688b8109a7f50a39a8 |
prelude: |\n ary2 = 2.times.to_a.shuffle\n ary10 = 10.times.to_a.shuffle\n ary100 = 100.times.to_a.shuffle\n ary500 = 500.times.to_a.shuffle\n ary1000 = 1000.times.to_a.shuffle\n ary2000 = 2500.times.to_a.shuffle\n ary3000 = 2500.times.to_a.shuffle\n ary5000 = 5000.times.to_a.shuffle\n ary10000 = 10000.times.to_a.shuffle\n ary20000 = 20000.times.to_a.shuffle\n ary50000 = 50000.times.to_a.shuffle\n ary100000 = 100000.times.to_a.shuffle\n ary1000000 = 1000000.times.to_a.shuffle\n\nbenchmark:\n ary2.min: ary2.min\n ary10.min: ary10.min\n ary100.min: ary100.min\n ary500.min: ary500.min\n ary1000.min: ary1000.min\n ary2000.min: ary2000.min\n ary3000.min: ary3000.min\n ary5000.min: ary5000.min\n ary10000.min: ary10000.min\n ary20000.min: ary20000.min\n ary50000.min: ary50000.min\n ary100000.min: ary100000.min\n ary1000000.min: ary1000000.min\n\nloop_count: 10000\n | dataset_sample\yaml\ruby_ruby\benchmark\array_min.yml | array_min.yml | YAML | 865 | 0.7 | 0 | 0 | react-lib | 394 | 2024-10-27T06:56:28.375106 | MIT | false | 682a5f0e72dba76820fd4f58a5e991db |
prelude: |\n ary2 = 2.times.to_a.shuffle\n ary10 = 10.times.to_a.shuffle\n ary100 = 100.times.to_a.shuffle\n ary1000 = 1000.times.to_a.shuffle\n ary10000 = 10000.times.to_a.shuffle\n\nbenchmark:\n ary2.sort: ary2.sort\n ary10.sort: ary10.sort\n ary100.sort: ary100.sort\n ary1000.sort: ary1000.sort\n ary10000.sort: ary10000.sort\n\nloop_count: 10000\n | dataset_sample\yaml\ruby_ruby\benchmark\array_sort_int.yml | array_sort_int.yml | YAML | 347 | 0.7 | 0 | 0 | awesome-app | 432 | 2024-05-16T03:55:19.931377 | GPL-3.0 | false | c6087276e45e043303ec5016e21691c1 |
prelude: |\n class C\n attr_accessor :x\n def initialize\n @x = nil\n end\n class_eval <<-END\n def ar\n #{'x;'*256}\n end\n def aw\n #{'self.x = nil;'*256}\n end\n def arm\n m = method(:x)\n #{'m.call;'*256}\n end\n def awm\n m = method(:x=)\n #{'m.call(nil);'*256}\n end\n END\n end\n obj = C.new\nbenchmark:\n attr_reader: "obj.ar"\n attr_writer: "obj.aw"\n attr_reader_method: "obj.arm"\n attr_writer_method: "obj.awm"\n | dataset_sample\yaml\ruby_ruby\benchmark\attr_accessor.yml | attr_accessor.yml | YAML | 504 | 0.95 | 0.206897 | 0.137931 | vue-tools | 752 | 2024-09-21T19:35:32.987286 | MIT | false | 2cf15b01ca4165ba2a1b2b6838c04157 |
prelude: |\n # frozen_string_literal: true\n Warning[:experimental] = false\n string = "The quick brown fox jumped over the lazy dog."\n array = string.bytes\n buffer = IO::Buffer.for(string)\nbenchmark:\n string.each_byte: |\n upcased = String.new\n string.each_byte do |byte|\n upcased << (byte ^ 32)\n end\n array.each: |\n upcased = String.new\n array.each do |byte|\n upcased << (byte ^ 32)\n end\n buffer.each: |\n upcased = String.new\n buffer.each(:U8) do |offset, byte|\n upcased << (byte ^ 32)\n end\n buffer.each_byte: |\n upcased = String.new\n buffer.each_byte do |byte|\n upcased << (byte ^ 32)\n end\n | dataset_sample\yaml\ruby_ruby\benchmark\buffer_each.yml | buffer_each.yml | YAML | 654 | 0.8 | 0.037037 | 0.037037 | awesome-app | 465 | 2024-10-02T07:39:21.169719 | Apache-2.0 | false | 23991a1c4af4dea5b7b95d854a4120e1 |
prelude: |\n # frozen_string_literal: true\n Warning[:experimental] = false\n string = "The quick brown fox jumped over the lazy dog."\n buffer = IO::Buffer.for(string)\n format = [:U32, :U32, :U32, :U32]\nbenchmark:\n string.unpack1: |\n [\n string.unpack1("N"),\n string.unpack1("N", offset: 4),\n string.unpack1("N", offset: 8),\n string.unpack1("N", offset: 12),\n ]\n buffer.get_value: |\n [\n buffer.get_value(:U32, 0),\n buffer.get_value(:U32, 4),\n buffer.get_value(:U32, 8),\n buffer.get_value(:U32, 12),\n ]\n buffer.get_values: |\n buffer.get_values(format, 0)\n string.unpack: |\n string.unpack("NNNN")\n | dataset_sample\yaml\ruby_ruby\benchmark\buffer_get.yml | buffer_get.yml | YAML | 658 | 0.8 | 0.04 | 0.04 | awesome-app | 177 | 2024-02-10T01:19:27.106474 | MIT | false | 498c7fe05c61ae3adb61ddf0ef125f4e |
prelude: |\n # frozen_string_literal: true\n require 'cgi/escape'\nbenchmark:\n - script: CGI.escapeHTML("")\n loop_count: 20000000\n - script: CGI.escapeHTML("abcde")\n loop_count: 20000000\n - script: CGI.escapeHTML("abcd<")\n loop_count: 20000000\n - script: CGI.escapeHTML("'&\"<>")\n loop_count: 5000000\n - prelude: long_no_escape = "abcde" * 300\n script: CGI.escapeHTML(long_no_escape)\n loop_count: 1000000\n - prelude: long_all_escape = "'&\"<>" * 10\n script: CGI.escapeHTML(long_all_escape)\n loop_count: 1000000\n - prelude: | # http://example.com/\n example_html = <<~HTML\n <body>\n <div>\n <h1>Example Domain</h1>\n <p>This domain is established to be used for illustrative examples in documents. You may use this\n domain in examples without prior coordination or asking for permission.</p>\n <p><a href="http://www.iana.org/domains/example">More information...</a></p>\n </div>\n </body>\n HTML\n script: CGI.escapeHTML(example_html)\n loop_count: 1000000\n | dataset_sample\yaml\ruby_ruby\benchmark\cgi_escape_html.yml | cgi_escape_html.yml | YAML | 1,065 | 0.95 | 0.064516 | 0.032258 | node-utils | 937 | 2025-06-14T12:25:46.665785 | Apache-2.0 | false | 906150abaee7c91010ccb854659953b8 |
prelude: |\n max, min = 1000.0, -1000.0\n a = Complex(rand(max)+min, rand(max)+min)\n b = Complex(rand(max)+min, rand(max)+min)\nbenchmark:\n complex_float_add: c = a + b\nloop_count: 1000000\n | dataset_sample\yaml\ruby_ruby\benchmark\complex_float_add.yml | complex_float_add.yml | YAML | 190 | 0.7 | 0 | 0 | python-kit | 397 | 2024-04-11T10:39:06.948348 | GPL-3.0 | false | 4902220eb50571d738afb6466fc1ca0c |
prelude: |\n max, min = 1000.0, -1000.0\n a = Complex(rand(max)+min, rand(max)+min)\n b = Complex(rand(max)+min, rand(max)+min)\nbenchmark:\n complex_float_div: c = a / b\nloop_count: 1000000\n | dataset_sample\yaml\ruby_ruby\benchmark\complex_float_div.yml | complex_float_div.yml | YAML | 190 | 0.7 | 0 | 0 | react-lib | 610 | 2025-05-12T10:14:15.678403 | Apache-2.0 | false | 3ae94e7851c583f225e6660c4258782b |
prelude: |\n max, min = 1000.0, -1000.0\n a = Complex(rand(max)+min, rand(max)+min)\n b = Complex(rand(max)+min, rand(max)+min)\nbenchmark:\n complex_float_mul: c = a * b\nloop_count: 1000000\n | dataset_sample\yaml\ruby_ruby\benchmark\complex_float_mul.yml | complex_float_mul.yml | YAML | 190 | 0.7 | 0 | 0 | awesome-app | 852 | 2025-03-01T02:42:18.144148 | BSD-3-Clause | false | 005427a5b392c2b9784bae13a1742932 |
prelude: |\n max, min = 1000.0, -1000.0\n a = Complex(rand(max)+min, rand(max)+min)\n b = Complex(rand(max)+min, rand(max)+min)\nbenchmark:\n complex_float_new: c = Complex(a, b)\nloop_count: 1000000\n | dataset_sample\yaml\ruby_ruby\benchmark\complex_float_new.yml | complex_float_new.yml | YAML | 198 | 0.7 | 0 | 0 | awesome-app | 925 | 2024-05-05T09:42:55.840171 | BSD-3-Clause | false | e558d8f40f074e697b2df5818f1ca364 |
prelude: |\n max, min = 1000.0, -1000.0\n a = Complex(rand(max)+min, rand(max)+min)\n b = Complex(rand(max)+min, rand(max)+min)\nbenchmark:\n complex_float_power: c = a ** b\nloop_count: 1000000\n | dataset_sample\yaml\ruby_ruby\benchmark\complex_float_power.yml | complex_float_power.yml | YAML | 193 | 0.7 | 0 | 0 | node-utils | 556 | 2024-04-26T10:37:02.003307 | Apache-2.0 | false | a6c3cac6440469626d487225b20ba15f |
prelude: |\n max, min = 1000.0, -1000.0\n a = Complex(rand(max)+min, rand(max)+min)\n b = Complex(rand(max)+min, rand(max)+min)\nbenchmark:\n complex_float_sub: c = a - b\nloop_count: 1000000\n | dataset_sample\yaml\ruby_ruby\benchmark\complex_float_sub.yml | complex_float_sub.yml | YAML | 190 | 0.7 | 0 | 0 | react-lib | 382 | 2024-04-28T00:39:43.618084 | BSD-3-Clause | false | 5c50d4ed3ce039bdaba9ca8f9601b26e |
prelude: |\n num = (1..).lazy.take(100)\n ary2 = [[1,2]].cycle.lazy.take(10)\n ary10 = [[*1..10]].cycle.lazy.take(10)\n ary20 = [[*1..20]].cycle.lazy.take(10)\n ary50 = [[*1..50]].cycle.lazy.take(10)\n ary100 = [[*1..100]].cycle.lazy.take(10)\n\nbenchmark:\n num3: num.flat_map {|x| x}.take(3).to_a\n num10: num.flat_map {|x| x}.take(3).to_a\n ary2: ary2.flat_map {|x| x}.take(3).to_a\n ary10: ary10.flat_map {|x| x}.take(3).to_a\n ary20: ary20.flat_map {|x| x}.take(3).to_a\n ary50: ary50.flat_map {|x| x}.take(3).to_a\n ary100: ary100.flat_map {|x| x}.take(3).to_a\n | dataset_sample\yaml\ruby_ruby\benchmark\enum_lazy_flat_map.yml | enum_lazy_flat_map.yml | YAML | 566 | 0.7 | 0 | 0 | awesome-app | 518 | 2024-12-18T06:38:13.295828 | BSD-3-Clause | false | e44e18a9946fb3e32ef20bce4ff23a96 |
prelude: |\n a = (1..3).lazy\n b = a.map {|x| x}\n\nbenchmark:\n first_ary: a.zip(["a", "b", "c"]).first\n first_nonary: a.zip("a".."c").first\n first_noarg: a.zip.first\n\n take3_ary: a.zip(["a", "b", "c"]).take(3).force\n take3_nonary: a.zip("a".."c").take(3).force\n take3_noarg: a.zip.take(3).force\n\n chain-first_ary: b.zip(["a", "b", "c"]).first\n chain-first_nonary: b.zip("a".."c").first\n chain-first_noarg: b.zip.first\n\n chain-take3_ary: b.zip(["a", "b", "c"]).take(3).force\n chain-take3_nonary: b.zip("a".."c").take(3).force\n chain-take3_noarg: b.zip.take(3).force\n\n block: a.zip("a".."c") {|x, y| [x, y]}\n | dataset_sample\yaml\ruby_ruby\benchmark\enum_lazy_zip.yml | enum_lazy_zip.yml | YAML | 618 | 0.7 | 0 | 0 | python-kit | 167 | 2023-08-03T10:13:43.724805 | MIT | false | 623d5a85c43920e1b88fe93a8fd64c24 |
prelude: |\n set2 = 2.times.to_a.shuffle.to_set\n set10 = 10.times.to_a.shuffle.to_set\n set100 = 100.times.to_a.shuffle.to_set\n set1000 = 1000.times.to_a.shuffle.to_set\n set10000 = 10000.times.to_a.shuffle.to_set\n\nbenchmark:\n set2.min: set2.min\n set10.min: set10.min\n set100.min: set100.min\n set1000.min: set1000.min\n set10000.min: set10000.min\n set2.max: set2.max\n set10.max: set10.max\n set100.max: set100.max\n set1000.max: set1000.max\n set10000.max: set10000.max\n set2.minmax: set2.minmax\n set10.minmax: set10.minmax\n set100.minmax: set100.minmax\n set1000.minmax: set1000.minmax\n set10000.minmax: set10000.minmax\n\nloop_count: 10000\n | dataset_sample\yaml\ruby_ruby\benchmark\enum_minmax.yml | enum_minmax.yml | YAML | 652 | 0.7 | 0 | 0 | vue-tools | 803 | 2024-08-22T02:58:58.912284 | Apache-2.0 | false | 1b909c615e07ad9ce108016b5f709220 |
prelude: |\n set2 = 2.times.to_a.shuffle.to_set\n set10 = 10.times.to_a.shuffle.to_set\n set100 = 100.times.to_a.shuffle.to_set\n set1000 = 1000.times.to_a.shuffle.to_set\n set10000 = 10000.times.to_a.shuffle.to_set\n\nbenchmark:\n set2.sort_by: set2.sort_by { 0 }\n set10.sort_by: set10.sort_by { 0 }\n set100.sort_by: set100.sort_by { 0 }\n set1000.sort_by: set1000.sort_by { 0 }\n set10000.sort_by: set10000.sort_by { 0 }\n\nloop_count: 10000\n | dataset_sample\yaml\ruby_ruby\benchmark\enum_sort.yml | enum_sort.yml | YAML | 442 | 0.7 | 0 | 0 | vue-tools | 931 | 2024-09-18T23:51:42.136365 | Apache-2.0 | false | fb2baded82197c021f5e1936485b53d7 |
prelude: |\n array_length = 2\n fixnum_array2 = array_length.times.to_a.map {rand(10000)}\n float_array2 = array_length.times.to_a.map {rand(10000.0).to_f}\n string_array2 = array_length.times.to_a.map {"r" * rand(1..10000)}\n mix_array2 = array_length.times.to_a.map {if rand(1..100) <= 50 then rand(1..10000).to_f else rand(1..10000) end}\n all_zero_array2 =array_length.times.to_a.map {0}\n\n array_length = 10\n fixnum_array10 = array_length.times.to_a.map {rand(10000)}\n float_array10 = array_length.times.to_a.map {rand(10000.0).to_f}\n string_array10 = array_length.times.to_a.map {"r" * rand(1..10000)}\n mix_array10 = array_length.times.to_a.map {if rand(1..100) <= 50 then rand(1..10000).to_f else rand(1..10000) end}\n all_zero_array10 =array_length.times.to_a.map {0}\n\n array_length = 1000\n fixnum_array1000 = array_length.times.to_a.map {rand(10000)}\n float_array1000 = array_length.times.to_a.map {rand(10000.0).to_f}\n string_array1000 = array_length.times.to_a.map {"r" * rand(1..10000)}\n mix_array1000 = array_length.times.to_a.map {if rand(1..100) <= 50 then rand(1..10000).to_f else rand(1..10000) end}\n all_zero_array1000 =array_length.times.to_a.map {0}\n\n array_length = 100000\n fixnum_array100000 = array_length.times.to_a.map {rand(10000)}\n float_array100000 = array_length.times.to_a.map {rand(10000.0).to_f}\n string_array100000 = array_length.times.to_a.map {"r" * rand(1..10000)}\n mix_array100000 = array_length.times.to_a.map {if rand(1..100) <= 50 then rand(1..10000).to_f else rand(1..10000) end}\n all_zero_array100000 =array_length.times.to_a.map {0}\n\nbenchmark:\n fixnum_array2.sort_by: fixnum_array2.sort_by {|a| a}\n float_array2.sort_by: float_array2.sort_by {|a| a}\n string_length2.sort_by: string_array2.sort_by {|a| a.length}\n mix_array2.sort_by: mix_array2.sort_by {|a| a}\n all_zero2.sort_by: all_zero_array2.sort_by{|a| a}\n\n fixnum_array10.sort_by: fixnum_array10.sort_by {|a| a}\n float_array10.sort_by: float_array10.sort_by {|a| a}\n string_length10.sort_by: string_array10.sort_by {|a| a.length}\n mix_array10.sort_by: mix_array10.sort_by {|a| a}\n all_zero10.sort_by: all_zero_array10.sort_by{|a| a}\n\n fixnum_array1000.sort_by: fixnum_array1000.sort_by {|a| a}\n float_array1000.sort_by: float_array1000.sort_by {|a| a}\n string_length1000.sort_by: string_array1000.sort_by {|a| a.length}\n mix_array1000.sort_by: mix_array1000.sort_by {|a| a}\n all_zero1000.sort_by: all_zero_array1000.sort_by{|a| a}\n\n fixnum_array100000.sort_by: fixnum_array100000.sort_by {|a| a}\n float_array100000.sort_by: float_array100000.sort_by {|a| a}\n string_length100000.sort_by: string_array100000.sort_by {|a| a.length}\n mix_array100000.sort_by: mix_array100000.sort_by {|a| a}\n all_zero100000.sort_by: all_zero_array100000.sort_by{|a| a}\n | dataset_sample\yaml\ruby_ruby\benchmark\enum_sort_by.yml | enum_sort_by.yml | YAML | 2,793 | 0.7 | 0.075472 | 0 | awesome-app | 703 | 2024-11-14T19:47:22.858542 | Apache-2.0 | false | 528487ab213b358a8aae3195b7d7713a |
prelude: |\n # frozen_string_literal: true\n require 'erb'\nbenchmark:\n - script: ERB::Util.html_escape("")\n loop_count: 20000000\n - script: ERB::Util.html_escape("abcde")\n loop_count: 20000000\n - script: ERB::Util.html_escape("abcd<")\n loop_count: 20000000\n - script: ERB::Util.html_escape("'&\"<>")\n loop_count: 5000000\n - prelude: long_no_escape = "abcde" * 300\n script: ERB::Util.html_escape(long_no_escape)\n loop_count: 1000000\n - prelude: long_all_escape = "'&\"<>" * 10\n script: ERB::Util.html_escape(long_all_escape)\n loop_count: 1000000\n - prelude: | # http://example.com/\n example_html = <<~HTML\n <body>\n <div>\n <h1>Example Domain</h1>\n <p>This domain is established to be used for illustrative examples in documents. You may use this\n domain in examples without prior coordination or asking for permission.</p>\n <p><a href="http://www.iana.org/domains/example">More information...</a></p>\n </div>\n </body>\n HTML\n script: ERB::Util.html_escape(example_html)\n loop_count: 1000000\n | dataset_sample\yaml\ruby_ruby\benchmark\erb_escape_html.yml | erb_escape_html.yml | YAML | 1,107 | 0.95 | 0.064516 | 0.032258 | react-lib | 263 | 2025-06-06T02:12:54.379122 | BSD-3-Clause | false | 615dffd95878df47970e60765bbdd9cb |
prelude: |\n def make_link(previous)\n Fiber.new do\n while message = previous.resume\n Fiber.yield(message)\n end\n end\n end\n\n def make_chain(length = 1000, &block)\n chain = Fiber.new(&block)\n\n (length - 1).times do\n chain = make_link(chain)\n end\n\n return chain\n end\n\n message = "Hello World!"\n\n chain = make_chain do\n while true\n Fiber.yield(message)\n end\n end\nbenchmark:\n make_chain: |\n make_chain(100) do\n while true\n Fiber.yield(message)\n end\n end\n resume_chain: |\n chain.resume\nloop_count: 5000\n | dataset_sample\yaml\ruby_ruby\benchmark\fiber_chain.yml | fiber_chain.yml | YAML | 581 | 0.85 | 0.138889 | 0 | node-utils | 450 | 2024-09-03T16:05:02.890039 | BSD-3-Clause | false | a239c4dd110d3ea6ffe4546c140d4b96 |
prelude: |\n th = Thread.current\n th[:key] = :val\nbenchmark:\n key?: th.key?(:key)\n []: th[:key]\n keys: th.keys\nloop_count: 1_000_000\n | dataset_sample\yaml\ruby_ruby\benchmark\fiber_locals.yml | fiber_locals.yml | YAML | 137 | 0.7 | 0 | 0 | react-lib | 639 | 2024-02-04T22:25:48.186754 | BSD-3-Clause | false | 08779edeeed889dd3c561e983afa7139 |
prelude: |\n flo = 4.2\nbenchmark:\n to_f: |\n flo.to_f\n abs: |\n flo.abs\n magnitude: |\n flo.magnitude\n -@: |\n -flo\n zero?: |\n flo.zero?\nloop_count: 20000000\n | dataset_sample\yaml\ruby_ruby\benchmark\float_methods.yml | float_methods.yml | YAML | 174 | 0.7 | 0 | 0 | react-lib | 431 | 2024-04-07T09:12:28.717084 | Apache-2.0 | false | 25df89043e4971297c17529b3005927a |
prelude: |\n flo = 4.2\nbenchmark:\n negative?: |\n flo.negative?\n positive?: |\n flo.positive?\nloop_count: 20000000\n | dataset_sample\yaml\ruby_ruby\benchmark\float_neg_posi.yml | float_neg_posi.yml | YAML | 121 | 0.7 | 0 | 0 | node-utils | 909 | 2024-05-04T14:22:02.248840 | Apache-2.0 | false | 988d17072bb5d76356fa97f8df3509c0 |
prelude: |\n floats = [*0.0.step(1.0, 0.0001)]\n\nbenchmark:\n to_s: floats.each {|f| f.to_s}\n\nloop_count: 1000\n | dataset_sample\yaml\ruby_ruby\benchmark\float_to_s.yml | float_to_s.yml | YAML | 110 | 0.7 | 0 | 0 | python-kit | 113 | 2025-04-28T13:28:50.365730 | BSD-3-Clause | false | d3c80f06d482e42baee53bdfaf590733 |
prelude: |\n # frozen_string_literal: true\n hash = 10.times.to_h do |i|\n [i, i]\n end\n dyn_sym = "dynamic_symbol".to_sym\n binary = RubyVM::InstructionSequence.compile("# frozen_string_literal: true\n'iseq_load'").to_binary\n iseq_literal_string = RubyVM::InstructionSequence.load_from_binary(binary).eval\n\n hash[:some_symbol] = 1\n hash[dyn_sym] = 2\n hash["small"] = 3\n hash["frozen_string_literal"] = 4\n hash[iseq_literal_string] = 5\nbenchmark:\n symbol: hash[:some_symbol]\n dyn_symbol: hash[dyn_sym]\n small_lit: hash["small"]\n frozen_lit: hash["frozen_string_literal"]\n iseq_lit: hash[iseq_literal_string]\n | dataset_sample\yaml\ruby_ruby\benchmark\hash_aref_str_lit.yml | hash_aref_str_lit.yml | YAML | 622 | 0.8 | 0 | 0.052632 | node-utils | 338 | 2025-03-02T14:35:12.896334 | Apache-2.0 | false | 049d9b545158ad768d557c143cfc9faa |
prelude: |\n h = Hash.new { :foo }\nbenchmark:\n default_aref: h[1]\n default_method: h.default(1)\nloop_count: 1000000\n | dataset_sample\yaml\ruby_ruby\benchmark\hash_defaults.yml | hash_defaults.yml | YAML | 118 | 0.7 | 0 | 0 | vue-tools | 352 | 2024-12-30T08:31:03.026479 | BSD-3-Clause | false | 2d8bc51ece16ef22da50b6a6679c0a38 |
prelude: |\n small_hash = { a: 1 }\n larger_hash = 20.times.map { |i| [('a'.ord + i).chr.to_sym, i] }.to_h\n\nbenchmark:\n dup_small: small_hash.dup\n dup_larger: larger_hash.dup\nloop_count: 10000\n | dataset_sample\yaml\ruby_ruby\benchmark\hash_dup.yml | hash_dup.yml | YAML | 195 | 0.7 | 0 | 0 | react-lib | 403 | 2023-08-11T04:23:05.618044 | BSD-3-Clause | false | 73c72d2719538d348648cb758dfa018a |
prelude: |\n hash1 = 1_000_000.times.to_h { [rand, true]}\n hash2 = hash1.dup\n hash2.keys[1..100_000].each { hash2.delete _1 }\n hash2.delete hash2.first[0]\n\nbenchmark:\n hash1: hash1.first\n hash2: hash2.first\n\nloop_count: 100_000\n | dataset_sample\yaml\ruby_ruby\benchmark\hash_first.yml | hash_first.yml | YAML | 233 | 0.7 | 0 | 0 | react-lib | 936 | 2024-10-23T12:24:46.857778 | GPL-3.0 | false | a8fa733316b0b516b6005248f53c642b |
prelude: |\n obj = Object.new\n hash = { obj => true }\nbenchmark: hash.key?(obj)\nloop_count: 30000000\n | dataset_sample\yaml\ruby_ruby\benchmark\hash_key.yml | hash_key.yml | YAML | 102 | 0.7 | 0 | 0 | react-lib | 715 | 2024-03-16T07:23:44.551230 | MIT | false | 4da3f37f2b17107caf64428bb0668551 |
prelude: |\n has_hash_with_capa = Hash.instance_method(:initialize).parameters.include?([:key, :capacity])\n strings_1k = 1_000.times.map { |i| -i.to_s.freeze }\n strings_100k = 100_000.times.map { |i| -i.to_s.freeze }\nbenchmark:\n new: Hash.new\n new_with_capa_1k: |\n h = has_hash_with_capa ? Hash.new(capacity: strings_1k.size) : {}\n strings_1k.each do |x|\n h[x] = true\n end\n new_with_capa_100k: |\n h = has_hash_with_capa ? Hash.new(capacity: strings_100k.size) : {}\n strings_100k.each do |x|\n h[x] = true\n end\n | dataset_sample\yaml\ruby_ruby\benchmark\hash_new.yml | hash_new.yml | YAML | 542 | 0.7 | 0 | 0 | python-kit | 757 | 2025-02-10T04:59:11.536187 | BSD-3-Clause | false | 3b779d2aa20021350d07644d325005fe |
prelude: |\n require 'irb/color'\n code = <<~'CODE'\n def self.foo # bar\n :"erb #{ERB.new("<%= self %>", trim_mode: ?-).result}"\n end\n CODE\nbenchmark:\n irb_color_complete: |\n IRB::Color.colorize_code(code, complete: true)\n irb_color_incomplete: |\n IRB::Color.colorize_code(code, complete: false)\nloop_count: 2000000\n | dataset_sample\yaml\ruby_ruby\benchmark\irb_color.yml | irb_color.yml | YAML | 335 | 0.95 | 0.076923 | 0 | vue-tools | 873 | 2025-05-20T21:02:17.976740 | BSD-3-Clause | false | 78245f5e95899f848cff52b2ec532883 |
prelude: |\n # frozen_string_literal: true\n require 'rbconfig'\n irb_f = [File.join(File.dirname(RbConfig.ruby), 'irb'), '-f']\nbenchmark:\n irb_exec: |\n IO.popen(irb_f, 'w') do |io|\n io.write('exit')\n end\nloop_count: 30\n | dataset_sample\yaml\ruby_ruby\benchmark\irb_exec.yml | irb_exec.yml | YAML | 232 | 0.95 | 0 | 0.1 | python-kit | 309 | 2023-11-20T00:12:44.060622 | MIT | false | 1c49a1a0122d2ce87710547b164b807b |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.