<feed xmlns='http://www.w3.org/2005/Atom'>
<title>ruby.git/test/optparse, branch v4.0.4</title>
<subtitle>The Ruby Programming Language</subtitle>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/'/>
<entry>
<title>[ruby/optparse] Use `~/.config` only if `$XDG_CONFIG_HOME` is unset or empty</title>
<updated>2025-08-08T10:39:20+00:00</updated>
<author>
<name>Nobuyoshi Nakada</name>
<email>nobu@ruby-lang.org</email>
</author>
<published>2025-08-08T10:33:00+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=f76ce9fd28bd0e94c7b2b904bf27958a6db1aed9'/>
<id>f76ce9fd28bd0e94c7b2b904bf27958a6db1aed9</id>
<content type='text'>
https://github.com/ruby/optparse/commit/2f9c7500a3
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
https://github.com/ruby/optparse/commit/2f9c7500a3
</pre>
</div>
</content>
</entry>
<entry>
<title>[ruby/optparse] Expand literal home paths only</title>
<updated>2025-08-03T13:53:27+00:00</updated>
<author>
<name>Nobuyoshi Nakada</name>
<email>nobu@ruby-lang.org</email>
</author>
<published>2025-08-03T13:41:21+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=deb0240ea06d3353fe3238d41f2534d9acc108a9'/>
<id>deb0240ea06d3353fe3238d41f2534d9acc108a9</id>
<content type='text'>
Paths in environment variables should already be expanded.
The base name of the program is also not subject to expansion.

https://github.com/ruby/optparse/commit/181752391c
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Paths in environment variables should already be expanded.
The base name of the program is also not subject to expansion.

https://github.com/ruby/optparse/commit/181752391c
</pre>
</div>
</content>
</entry>
<entry>
<title>[ruby/optparse] Fallback HOME</title>
<updated>2025-08-03T13:53:27+00:00</updated>
<author>
<name>Nobuyoshi Nakada</name>
<email>nobu@ruby-lang.org</email>
</author>
<published>2025-08-03T13:37:53+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=1619afb3500bb695140df6e9dacaa901bc21920c'/>
<id>1619afb3500bb695140df6e9dacaa901bc21920c</id>
<content type='text'>
https://github.com/ruby/optparse/commit/e0fdabf946
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
https://github.com/ruby/optparse/commit/e0fdabf946
</pre>
</div>
</content>
</entry>
<entry>
<title>[ruby/optparse] JRuby does not have EXECUTABLE_EXTS in RbConfg::CONFIG</title>
<updated>2025-06-29T07:52:46+00:00</updated>
<author>
<name>Nobuyoshi Nakada</name>
<email>nobu@ruby-lang.org</email>
</author>
<published>2025-06-29T07:50:09+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=9598ed9d1c56e971e76d4bbbacef6ec9643e12dc'/>
<id>9598ed9d1c56e971e76d4bbbacef6ec9643e12dc</id>
<content type='text'>
https://github.com/ruby/optparse/commit/15b2f00b6b
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
https://github.com/ruby/optparse/commit/15b2f00b6b
</pre>
</div>
</content>
</entry>
<entry>
<title>[ruby/optparse] Fix OptionParser#program_name not to strip suffix unexpectedly</title>
<updated>2025-06-29T07:52:45+00:00</updated>
<author>
<name>Nobuyoshi Nakada</name>
<email>nobu@ruby-lang.org</email>
</author>
<published>2025-06-29T07:07:07+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=259b0233d826104840d0b52ebb14e0a3435d4497'/>
<id>259b0233d826104840d0b52ebb14e0a3435d4497</id>
<content type='text'>
https://github.com/ruby/optparse/commit/740ffa76c0
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
https://github.com/ruby/optparse/commit/740ffa76c0
</pre>
</div>
</content>
</entry>
<entry>
<title>[ruby/optparse] Enhance to support 'Set' object as an enum</title>
<updated>2025-06-29T07:30:58+00:00</updated>
<author>
<name>kwatch</name>
<email>kwatch@gmail.com</email>
</author>
<published>2025-06-29T07:30:50+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=9fd793e0bd88e6b573fd4363595b3d7019b8c3b9'/>
<id>9fd793e0bd88e6b573fd4363595b3d7019b8c3b9</id>
<content type='text'>
(https://github.com/ruby/optparse/pull/76)

* Enhance to support 'Set' object as an enum

* Add test script for '#make_swithc()'

---------

https://github.com/ruby/optparse/commit/3869000e98

Co-authored-by: Nobuyoshi Nakada &lt;nobu@ruby-lang.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
(https://github.com/ruby/optparse/pull/76)

* Enhance to support 'Set' object as an enum

* Add test script for '#make_swithc()'

---------

https://github.com/ruby/optparse/commit/3869000e98

Co-authored-by: Nobuyoshi Nakada &lt;nobu@ruby-lang.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[ruby/optparse] Fix completion of key-value pairs array</title>
<updated>2025-03-17T10:18:49+00:00</updated>
<author>
<name>Nobuyoshi Nakada</name>
<email>nobu@ruby-lang.org</email>
</author>
<published>2025-03-17T10:13:47+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=8f19f0aad5f87d481b5ae4337afdb844bcce1885'/>
<id>8f19f0aad5f87d481b5ae4337afdb844bcce1885</id>
<content type='text'>
Enum array may be the list of pairs of key and value.  Check if only
key is completable, not pair.

Fix https://github.com/ruby/optparse/pull/93
Fix https://github.com/ruby/optparse/pull/94

https://github.com/ruby/optparse/commit/a8d0ba8dac
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Enum array may be the list of pairs of key and value.  Check if only
key is completable, not pair.

Fix https://github.com/ruby/optparse/pull/93
Fix https://github.com/ruby/optparse/pull/94

https://github.com/ruby/optparse/commit/a8d0ba8dac
</pre>
</div>
</content>
</entry>
<entry>
<title>[ruby/optparse] Make the result of `tty?` obtainable with flexible stdout</title>
<updated>2025-03-10T10:19:58+00:00</updated>
<author>
<name>Koichi ITO</name>
<email>koic.ito@gmail.com</email>
</author>
<published>2025-02-02T07:17:37+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=f4c16c57aad9138f236f4fa966893b21d5a64cbf'/>
<id>f4c16c57aad9138f236f4fa966893b21d5a64cbf</id>
<content type='text'>
In mock testing for stdout, `StringIO.new` is sometimes used to redirect the output.
In such cases, the assignment is done with `$stdout = StringIO.new`, not the constant `STDOUT`.
e.g., https://github.com/rubocop/rubocop/blob/v1.71.1/lib/rubocop/rspec/shared_contexts.rb#L154-L164

After assigning `StringIO.new`, `$stdout.tty?` returns `false`,
allowing the standard output destination to be switched during test execution.

```ruby
STDOUT.tty?       # =&gt; true
StringIO.new.tty? # =&gt; false
```

However, since `STDOUT.tty?` returns `true`, a failure occurred in environments
where the environment variables `RUBY_PAGER` or `PAGER` are set.
e.g., https://github.com/rubocop/rubocop/pull/13784

To address this, `STDOUT` has been updated to `$stdout` so that the result of `tty?` can be flexibly overridden.

A potential concern is that `$stdout`, unlike `STDOUT`,
does not always represent the standard output at the time the Ruby process started.
However, no concrete examples of issues related to this have been identified.

`STDOUT.tty?` is the logic of optparse introduced in https://github.com/ruby/optparse/pull/70.

This PR replaces `STDOUT` with `$stdout` throughout, based on the assumption
that `$stdout` is sufficient for use with optparse.

https://github.com/ruby/optparse/commit/262cf6f9ac
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
In mock testing for stdout, `StringIO.new` is sometimes used to redirect the output.
In such cases, the assignment is done with `$stdout = StringIO.new`, not the constant `STDOUT`.
e.g., https://github.com/rubocop/rubocop/blob/v1.71.1/lib/rubocop/rspec/shared_contexts.rb#L154-L164

After assigning `StringIO.new`, `$stdout.tty?` returns `false`,
allowing the standard output destination to be switched during test execution.

```ruby
STDOUT.tty?       # =&gt; true
StringIO.new.tty? # =&gt; false
```

However, since `STDOUT.tty?` returns `true`, a failure occurred in environments
where the environment variables `RUBY_PAGER` or `PAGER` are set.
e.g., https://github.com/rubocop/rubocop/pull/13784

To address this, `STDOUT` has been updated to `$stdout` so that the result of `tty?` can be flexibly overridden.

A potential concern is that `$stdout`, unlike `STDOUT`,
does not always represent the standard output at the time the Ruby process started.
However, no concrete examples of issues related to this have been identified.

`STDOUT.tty?` is the logic of optparse introduced in https://github.com/ruby/optparse/pull/70.

This PR replaces `STDOUT` with `$stdout` throughout, based on the assumption
that `$stdout` is sufficient for use with optparse.

https://github.com/ruby/optparse/commit/262cf6f9ac
</pre>
</div>
</content>
</entry>
<entry>
<title>[ruby/optparse] Add post-check of value</title>
<updated>2025-03-10T09:55:29+00:00</updated>
<author>
<name>Nobuyoshi Nakada</name>
<email>nobu@ruby-lang.org</email>
</author>
<published>2025-03-10T04:12:34+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=9e265b583b5cc35b8120978c855e1a6a78abbe5b'/>
<id>9e265b583b5cc35b8120978c855e1a6a78abbe5b</id>
<content type='text'>
Fix https://github.com/ruby/optparse/pull/80

https://github.com/ruby/optparse/commit/050a87d029
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fix https://github.com/ruby/optparse/pull/80

https://github.com/ruby/optparse/commit/050a87d029
</pre>
</div>
</content>
</entry>
<entry>
<title>[ruby/optparse] Allow non-string enum list #79</title>
<updated>2025-03-09T14:32:17+00:00</updated>
<author>
<name>Nobuyoshi Nakada</name>
<email>nobu@ruby-lang.org</email>
</author>
<published>2025-03-09T13:39:12+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=cdf36d6bfd6409b8c626557aca7abf74b7e4e76c'/>
<id>cdf36d6bfd6409b8c626557aca7abf74b7e4e76c</id>
<content type='text'>
Command line arguments are strings, convert enum list elements to
strings to match.

https://github.com/ruby/optparse/commit/c5ec052efc
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Command line arguments are strings, convert enum list elements to
strings to match.

https://github.com/ruby/optparse/commit/c5ec052efc
</pre>
</div>
</content>
</entry>
</feed>
