From 3cdafe9be19c7d8b9351f68338b0b94bac9903ee Mon Sep 17 00:00:00 2001 From: Nobuyoshi Nakada Date: Mon, 5 Jun 2023 18:43:33 +0900 Subject: [PATCH] Move per sections in help message --- ruby.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/ruby.c b/ruby.c index 7b233e4106..b2d412c49d 100644 --- a/ruby.c +++ b/ruby.c @@ -1801,7 +1801,10 @@ rb_f_chomp(int argc, VALUE *argv, VALUE _) static void setup_pager_env(void) { - if (!getenv("LESS")) ruby_setenv("LESS", "-R"); // Output "raw" control characters. + if (!getenv("LESS")) { + // Output "raw" control characters, and move per sections. + ruby_setenv("LESS", "-R +/^[A-Z].*"); + } } #ifdef _WIN32