ruby-changes:71801
From: Stan <ko1@a...>
Date: Thu, 12 May 2022 04:13:12 +0900 (JST)
Subject: [ruby-changes:71801] 26a07b8b46 (master): Add a separate doc for contributing to stdlibs [ci skip]
https://git.ruby-lang.org/ruby.git/commit/?id=26a07b8b46 From 26a07b8b46d0ae775d01c023146881564f285419 Mon Sep 17 00:00:00 2001 From: Stan Lo <stan.lo@s...> Date: Wed, 11 May 2022 17:03:39 +0100 Subject: Add a separate doc for contributing to stdlibs [ci skip] co-authored-by: Peter Zhu <peter@p...> --- doc/contributing.md | 5 +-- doc/contributing/making_changes_to_ruby.md | 8 ----- doc/contributing/making_changes_to_stdlibs.md | 49 +++++++++++++++++++++++++++ 3 files changed, 52 insertions(+), 10 deletions(-) create mode 100644 doc/contributing/making_changes_to_stdlibs.md diff --git a/doc/contributing.md b/doc/contributing.md index 1f53e6f56e..a8deea7969 100644 --- a/doc/contributing.md +++ b/doc/contributing.md @@ -5,6 +5,7 @@ This guide outlines ways to get started with contributing to Ruby: https://github.com/ruby/ruby/blob/trunk/doc/contributing.md#L5 * [Reporting issues](contributing/reporting_issues.md): How to report issues, how to request features, and how backporting works * [Building Ruby](contributing/building_ruby.md): How to build Ruby on your local machine for development * [Testing Ruby](contributing/testing_ruby.md): How to test Ruby on your local machine once you've built it -* [Making changes to Ruby](contributing/making_changes_to_ruby.md): How to submit pull requests +* [Making changes to Ruby](contributing/making_changes_to_ruby.md): How to submit pull requests to change Ruby's documentation, code, test suite, or standard libraries -* [Making changes to Ruby documentation](contributing/documentation_guide.md): How to make changes to Ruby documentation \ No newline at end of file +* [Making changes to Ruby standard libraries](contributing/making_changes_to_stdlibs.md): How to build, test, and contribute to Ruby standard libraries +* [Making changes to Ruby documentation](contributing/documentation_guide.md): How to make changes to Ruby documentation diff --git a/doc/contributing/making_changes_to_ruby.md b/doc/contributing/making_changes_to_ruby.md index 6842ec2888..260fadb7e3 100644 --- a/doc/contributing/making_changes_to_ruby.md +++ b/doc/contributing/making_changes_to_ruby.md @@ -26,11 +26,3 @@ Use the following style for commit messages: https://github.com/ruby/ruby/blob/trunk/doc/contributing/making_changes_to_ruby.md#L26 GitHub actions will run on each pull request. There is [a CI that runs on master](https://rubyci.org/). It has broad coverage of different systems and architectures, such as Solaris SPARC and macOS. - -# Contributing to standard libraries - -Everything in the [lib](https://github.com/ruby/ruby/tree/master/lib) directory is mirrored from a standalone repository into the Ruby repository. -If you'd like to make contributions to standard libraries, do so in the standalone repositories, and the -changes will be automatically mirrored into the Ruby repository. - -For example, CSV lives in [a separate repository](https://github.com/ruby/csv) and is mirrored into [Ruby](https://github.com/ruby/ruby/tree/master/lib/csv). diff --git a/doc/contributing/making_changes_to_stdlibs.md b/doc/contributing/making_changes_to_stdlibs.md new file mode 100644 index 0000000000..ef3811ea12 --- /dev/null +++ b/doc/contributing/making_changes_to_stdlibs.md @@ -0,0 +1,49 @@ https://github.com/ruby/ruby/blob/trunk/doc/contributing/making_changes_to_stdlibs.md#L1 +# Making Changes To Standard Libraries + +Everything in the [lib](https://github.com/ruby/ruby/tree/master/lib) directory is mirrored from a standalone repository into the Ruby repository. +If you'd like to make contributions to standard libraries, do so in the standalone repositories, and the +changes will be automatically mirrored into the Ruby repository. + +For example, CSV lives in [a separate repository](https://github.com/ruby/csv) and is mirrored into [Ruby](https://github.com/ruby/ruby/tree/master/lib/csv). + +## Maintainers + +You can find the list of maintainers [here](https://docs.ruby-lang.org/en/master/maintainers_rdoc.html#label-Maintainers). + +## Build + +First, install its dependencies using: + +``` +bundle install +``` + +### Libraries with C-extension + +If the library has a `/ext` directory, it has C files that you need to compile with: + +``` +bundle exec rake compile +``` + +## Running tests + +All standard libraries use [test-unit](https://github.com/test-unit/test-unit) as the test framework. + +To run all tests: + +``` +bundle exec rake test +``` + +To run a single test file: + +``` +bundle exec rake test TEST="test/test_foo.rb" +``` + +To run a single test case: + +``` +bundle exec rake test TEST="test/test_foo.rb" TESTOPS="--name=/test_mytest/" +``` -- cgit v1.2.1 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/