* [PATCH] git-send-email: Do not send editor backup files in a directory
@ 2011-07-22 7:29 Joe Perches
2011-07-29 0:41 ` Joe Perches
2011-07-29 6:47 ` Ramkumar Ramachandra
0 siblings, 2 replies; 3+ messages in thread
From: Joe Perches @ 2011-07-22 7:29 UTC (permalink / raw)
To: git
Sift out backup files that are commonly created by editors.
Signed-off-by: Joe Perches <joe@perches.com>
---
git-send-email.perl | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/git-send-email.perl b/git-send-email.perl
index 98ab33a..a4558d9 100755
--- a/git-send-email.perl
+++ b/git-send-email.perl
@@ -521,7 +521,9 @@ while (defined(my $f = shift @ARGV)) {
opendir my $dh, $f
or die "Failed to opendir $f: $!";
- push @files, grep { -f $_ } map { catfile($f, $_) }
+ push @files, grep { !/#.+#$/ && !/~$/ &&
+ !/\.bak$/ && !/\.orig$/ &&
+ -f $_ } map { catfile($f, $_) }
sort readdir $dh;
closedir $dh;
} elsif ((-f $f or -p $f) and !check_file_rev_conflict($f)) {
--
1.7.6.131.g99019
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] git-send-email: Do not send editor backup files in a directory
2011-07-22 7:29 [PATCH] git-send-email: Do not send editor backup files in a directory Joe Perches
@ 2011-07-29 0:41 ` Joe Perches
2011-07-29 6:47 ` Ramkumar Ramachandra
1 sibling, 0 replies; 3+ messages in thread
From: Joe Perches @ 2011-07-29 0:41 UTC (permalink / raw)
To: git
Joe Perches <joe <at> perches.com> writes:
> Sift out backup files that are commonly created by editors.
Ping?
--------------
diff --git a/git-send-email.perl b/git-send-email.perl
[]
@@ -521,7 +521,9 @@ while (defined(my $f = shift @ARGV)) {
[]
- push @files, grep { -f $_ } map { catfile($f, $_) }
+ push @files, grep { !/#.+#$/ && !/~$/ &&
+ !/\.bak$/ && !/\.orig$/ &&
+ -f $_ } map { catfile($f, $_) }
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] git-send-email: Do not send editor backup files in a directory
2011-07-22 7:29 [PATCH] git-send-email: Do not send editor backup files in a directory Joe Perches
2011-07-29 0:41 ` Joe Perches
@ 2011-07-29 6:47 ` Ramkumar Ramachandra
1 sibling, 0 replies; 3+ messages in thread
From: Ramkumar Ramachandra @ 2011-07-29 6:47 UTC (permalink / raw)
To: Joe Perches; +Cc: git, Junio C Hamano
Hi Joe,
Joe Perches writes
> [Subject: git-send-email: Do not send editor backup files in a directory]
I like this change. I don't have to resort to my normal `git
send-email outgoing/*.patch` anymore.
Thanks.
-- Ram
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2011-07-29 6:47 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-07-22 7:29 [PATCH] git-send-email: Do not send editor backup files in a directory Joe Perches
2011-07-29 0:41 ` Joe Perches
2011-07-29 6:47 ` Ramkumar Ramachandra
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).