From: Pavel Roskin <proski@gnu.org>
To: Catalin Marinas <catalin.marinas@gmail.com>, git@vger.kernel.org
Subject: [PATCH 2/2] Fix refresh -es
Date: Thu, 30 Aug 2007 23:04:55 -0400 [thread overview]
Message-ID: <20070831030455.22554.75625.stgit@dv.roinet.com> (raw)
In-Reply-To: <20070831030449.22554.49699.stgit@dv.roinet.com>
Use named arguments to call git.diff() from stack.edit_file().
git.diff() doesn't write to files anymore, do it in the caller.
Signed-off-by: Pavel Roskin <proski@gnu.org>
---
stgit/stack.py | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/stgit/stack.py b/stgit/stack.py
index ea22d76..0253348 100644
--- a/stgit/stack.py
+++ b/stgit/stack.py
@@ -88,7 +88,8 @@ def edit_file(series, line, comment, show_patch = True):
if show_patch:
print >> f, __patch_prefix
# series.get_patch(series.get_current()).get_top()
- git.diff([], series.get_patch(series.get_current()).get_bottom(), None, f)
+ diff_str = git.diff(rev1 = series.get_patch(series.get_current()).get_bottom())
+ f.write(diff_str)
#Vim modeline must be near the end.
print >> f, __comment_prefix, 'vi: set textwidth=75 filetype=diff nobackup:'
prev parent reply other threads:[~2007-08-31 3:05 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-08-31 3:04 [PATCH 1/2] Use --force to overwrite python files Pavel Roskin
2007-08-31 3:04 ` Pavel Roskin [this message]
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=20070831030455.22554.75625.stgit@dv.roinet.com \
--to=proski@gnu.org \
--cc=catalin.marinas@gmail.com \
--cc=git@vger.kernel.org \
/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 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).