All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Pavel Dydyshko via GitGitGadget" <gitgitgadget@gmail.com>
To: git@vger.kernel.org
Cc: Pavel Dydyshko <paul.dydyshko@gmail.com>,
	Pavel Dydyshka <paul.dydyshko@gmail.com>
Subject: [PATCH] svn: add multi-line support for ignore-paths and include-paths
Date: Fri, 31 Oct 2025 13:26:37 +0000	[thread overview]
Message-ID: <pull.2091.git.git.1761917197824.gitgitgadget@gmail.com> (raw)

From: Pavel Dydyshka <paul.dydyshko@gmail.com>

Allow multiple ignore-paths and include-paths entries in config. Instead
of reading single entry and storing it as is editor now concatenates all
values through a '|'

Signed-off-by: Pavel Dydyshka <paul.dydyshko@gmail.com>
---
    svn: add multi-line support for ignore-paths and include-paths

Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-git-2091%2Fpddshk%2Fsvn-multi-line-ignore-include-v1
Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-git-2091/pddshk/svn-multi-line-ignore-include-v1
Pull-Request: https://github.com/git/git/pull/2091

 perl/Git/SVN/Fetcher.pm | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/perl/Git/SVN/Fetcher.pm b/perl/Git/SVN/Fetcher.pm
index 968309e6d6..b2991480e1 100644
--- a/perl/Git/SVN/Fetcher.pm
+++ b/perl/Git/SVN/Fetcher.pm
@@ -31,15 +31,15 @@ sub new {
 	# override options set in an [svn-remote "..."] section
 	$repo_id = $git_svn->{repo_id};
 	my $k = "svn-remote.$repo_id.ignore-paths";
-	my $v = eval { command_oneline('config', '--get', $k) };
-	$self->{ignore_regex} = $v;
+	my @ignores = eval { command('config', '--get-all', $k) };
+	$self->{ignore_regex} = join('|', @ignores) if @ignores;
 
 	$k = "svn-remote.$repo_id.include-paths";
-	$v = eval { command_oneline('config', '--get', $k) };
-	$self->{include_regex} = $v;
+	my @includes = eval { command('config', '--get-all', $k) };
+	$self->{include_regex} = join('|', @includes) if @includes;
 
 	$k = "svn-remote.$repo_id.preserve-empty-dirs";
-	$v = eval { command_oneline('config', '--get', '--bool', $k) };
+	my $v = eval { command_oneline('config', '--get', '--bool', $k) };
 	if ($v && $v eq 'true') {
 		$_preserve_empty_dirs = 1;
 		$k = "svn-remote.$repo_id.placeholder-filename";

base-commit: 419c72cb8ada252b260efc38ff91fe201de7c8c3
-- 
gitgitgadget

                 reply	other threads:[~2025-10-31 13:26 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=pull.2091.git.git.1761917197824.gitgitgadget@gmail.com \
    --to=gitgitgadget@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=paul.dydyshko@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.